From be4d0491d9e442d536e85ce1e95672ade54c03c0 Mon Sep 17 00:00:00 2001 From: srnyx <25808801+srnyx@users.noreply.github.com> Date: Mon, 10 Mar 2025 18:45:04 -0400 Subject: [PATCH 1/3] Apply #262 to Python entrypoint Works on a local/private docker image --- python/entrypoint.sh | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/python/entrypoint.sh b/python/entrypoint.sh index aab4aea..975cf28 100644 --- a/python/entrypoint.sh +++ b/python/entrypoint.sh @@ -8,9 +8,13 @@ export INTERNAL_IP # Print current Python version python --version -# Replace Startup Variables -MODIFIED_STARTUP=$(echo -e $(echo -e ${STARTUP} | sed -e 's/{{/${/g' -e 's/}}/}/g')) -echo -e ":/home/container$ ${MODIFIED_STARTUP}" +# Convert all of the "{{VARIABLE}}" parts of the command into the expected shell +# variable format of "${VARIABLE}" before evaluating the string and automatically +# replacing the values. +PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') -# Run the Server -eval ${MODIFIED_STARTUP} +# Display the command we're running in the output, and then execute it with eval +printf "\033[1m\033[33mcontainer@pelican~ \033[0m" +echo "$PARSED" +# shellcheck disable=SC2086 +eval "$PARSED" From 883aef96dd71dabaa97c48728d5949ebbdc8731e Mon Sep 17 00:00:00 2001 From: srnyx <25808801+srnyx@users.noreply.github.com> Date: Tue, 11 Mar 2025 16:38:56 -0400 Subject: [PATCH 2/3] Change `pelican` to `pterodactyl` --- cassandra/entrypoint.sh | 8 ++++---- dotnet/entrypoint.sh | 2 +- erlang/entrypoint.sh | 4 ++-- games/minetest/entrypoint.sh | 2 +- go/entrypoint.sh | 4 ++-- java/entrypoint.sh | 4 ++-- oses/alpine/entrypoint.sh | 2 +- python/entrypoint.sh | 2 +- voice/teaspeak/entrypoint.sh | 2 +- 9 files changed, 15 insertions(+), 15 deletions(-) diff --git a/cassandra/entrypoint.sh b/cassandra/entrypoint.sh index b91ad64..216e36a 100644 --- a/cassandra/entrypoint.sh +++ b/cassandra/entrypoint.sh @@ -12,17 +12,17 @@ export INTERNAL_IP cd /home/container || exit 1 # Print Java version -printf "\033[1m\033[33mcontainer@pelican~ \033[0mjava -version\n" +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mjava -version\n" java -version # Print Python version if command -v python &> /dev/null then - printf "\033[1m\033[33mcontainer@pelican~ \033[0mpython --version\n" + printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mpython --version\n" python --version else - printf "\033[1m\033[33mcontainer@pelican~ \033[0mpython3 --version\n" + printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mpython3 --version\n" python3 --version fi @@ -32,7 +32,7 @@ fi PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') # Display the command we're running in the output, and then execute it with eval -printf "\033[1m\033[33mcontainer@pelican~ \033[0m" +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m" echo "$PARSED" # shellcheck disable=SC2086 eval "$PARSED" diff --git a/dotnet/entrypoint.sh b/dotnet/entrypoint.sh index d072407..b9fd77c 100644 --- a/dotnet/entrypoint.sh +++ b/dotnet/entrypoint.sh @@ -9,7 +9,7 @@ export INTERNAL_IP export DOTNET_ROOT=/usr/share/ # print the dotnet version on startup -printf "\033[1m\033[33mcontainer@pelican~ \033[0mdotnet --version\n" +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mdotnet --version\n" dotnet --version # Replace Startup Variables diff --git a/erlang/entrypoint.sh b/erlang/entrypoint.sh index b657169..5ce5cae 100644 --- a/erlang/entrypoint.sh +++ b/erlang/entrypoint.sh @@ -10,7 +10,7 @@ export INTERNAL_IP cd /home/container || exit 1 # Print Erlang's version -printf "\033[1m\033[33mcontainer@pelican~ \033[0merl -noshell -eval 'erlang:display(erlang:system_info(system_version))' -eval 'init:stop()'\n" +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0merl -noshell -eval 'erlang:display(erlang:system_info(system_version))' -eval 'init:stop()'\n" erl -noshell -eval 'erlang:display(erlang:system_info(system_version))' -eval 'init:stop()' # Convert all of the "{{VARIABLE}}" parts of the command into the expected shell @@ -19,7 +19,7 @@ erl -noshell -eval 'erlang:display(erlang:system_info(system_version))' -eval 'i PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') # Display the command we're running in the output, and then execute it with eval -printf "\033[1m\033[33mcontainer@pelican~ \033[0m" +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m" echo "$PARSED" # shellcheck disable=SC2086 eval "$PARSED" diff --git a/games/minetest/entrypoint.sh b/games/minetest/entrypoint.sh index 505b263..399eb5a 100644 --- a/games/minetest/entrypoint.sh +++ b/games/minetest/entrypoint.sh @@ -12,7 +12,7 @@ export INTERNAL_IP cd /home/container || exit 1 # Print minetest version -printf "\033[1m\033[33mcontainer@pelican~ \033[0mminetest --version\n" +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mminetest --version\n" minetest --version # Replace Startup Variables diff --git a/go/entrypoint.sh b/go/entrypoint.sh index 5de2ba6..e9c7a62 100644 --- a/go/entrypoint.sh +++ b/go/entrypoint.sh @@ -34,7 +34,7 @@ export INTERNAL_IP cd /home/container || exit 1 # Print Go version -printf "\033[1m\033[33mcontainer@pelican~ \033[0mgo version\n" +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mgo version\n" go version # Convert all of the "{{VARIABLE}}" parts of the command into the expected shell @@ -43,7 +43,7 @@ go version PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') # Display the command we're running in the output, and then execute it with eval -printf "\033[1m\033[33mcontainer@pelican~ \033[0m" +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m" echo "$PARSED" # shellcheck disable=SC2086 eval "$PARSED" diff --git a/java/entrypoint.sh b/java/entrypoint.sh index 23b662a..25e5f5c 100755 --- a/java/entrypoint.sh +++ b/java/entrypoint.sh @@ -34,7 +34,7 @@ export INTERNAL_IP cd /home/container || exit 1 # Print Java version -printf "\033[1m\033[33mcontainer@pelican~ \033[0mjava -version\n" +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mjava -version\n" java -version # Convert all of the "{{VARIABLE}}" parts of the command into the expected shell @@ -43,7 +43,7 @@ java -version PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') # Display the command we're running in the output, and then execute it with eval -printf "\033[1m\033[33mcontainer@pelican~ \033[0m" +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m" echo "$PARSED" # shellcheck disable=SC2086 eval "$PARSED" diff --git a/oses/alpine/entrypoint.sh b/oses/alpine/entrypoint.sh index 2b81022..070cd85 100644 --- a/oses/alpine/entrypoint.sh +++ b/oses/alpine/entrypoint.sh @@ -37,7 +37,7 @@ cd /home/container || exit 1 PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') # Display the command we're running in the output, and then execute it with eval -printf "\033[1m\033[33mcontainer@pelican~ \033[0m" +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m" echo "$PARSED" # shellcheck disable=SC2086 eval "$PARSED" diff --git a/python/entrypoint.sh b/python/entrypoint.sh index 975cf28..978b2a1 100644 --- a/python/entrypoint.sh +++ b/python/entrypoint.sh @@ -14,7 +14,7 @@ python --version PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') # Display the command we're running in the output, and then execute it with eval -printf "\033[1m\033[33mcontainer@pelican~ \033[0m" +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m" echo "$PARSED" # shellcheck disable=SC2086 eval "$PARSED" diff --git a/voice/teaspeak/entrypoint.sh b/voice/teaspeak/entrypoint.sh index 6142333..b71bd42 100644 --- a/voice/teaspeak/entrypoint.sh +++ b/voice/teaspeak/entrypoint.sh @@ -18,7 +18,7 @@ echo "installed youtube-dl Version:" PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') # Display the command we're running in the output, and then execute it with eval -printf "\033[1m\033[33mcontainer@pelican~ \033[0m" +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m" echo "$PARSED" # shellcheck disable=SC2086 eval "$PARSED" From 4433174569f3ba1fa52de6383d7faccee78dc38b Mon Sep 17 00:00:00 2001 From: srnyx <25808801+srnyx@users.noreply.github.com> Date: Sun, 16 Mar 2025 00:08:35 -0400 Subject: [PATCH 3/3] Remove `@pterodactyl` from `container@pterodactyl` --- cassandra/entrypoint.sh | 8 ++++---- dotnet/entrypoint.sh | 2 +- erlang/entrypoint.sh | 4 ++-- games/minetest/entrypoint.sh | 4 ++-- go/entrypoint.sh | 4 ++-- java/entrypoint.sh | 4 ++-- oses/alpine/entrypoint.sh | 2 +- python/entrypoint.sh | 2 +- voice/teaspeak/entrypoint.sh | 2 +- 9 files changed, 16 insertions(+), 16 deletions(-) diff --git a/cassandra/entrypoint.sh b/cassandra/entrypoint.sh index 216e36a..279010e 100644 --- a/cassandra/entrypoint.sh +++ b/cassandra/entrypoint.sh @@ -12,17 +12,17 @@ export INTERNAL_IP cd /home/container || exit 1 # Print Java version -printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mjava -version\n" +printf "\033[1m\033[33mcontainer~ \033[0mjava -version\n" java -version # Print Python version if command -v python &> /dev/null then - printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mpython --version\n" + printf "\033[1m\033[33mcontainer~ \033[0mpython --version\n" python --version else - printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mpython3 --version\n" + printf "\033[1m\033[33mcontainer~ \033[0mpython3 --version\n" python3 --version fi @@ -32,7 +32,7 @@ fi PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') # Display the command we're running in the output, and then execute it with eval -printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m" +printf "\033[1m\033[33mcontainer~ \033[0m" echo "$PARSED" # shellcheck disable=SC2086 eval "$PARSED" diff --git a/dotnet/entrypoint.sh b/dotnet/entrypoint.sh index b9fd77c..838f928 100644 --- a/dotnet/entrypoint.sh +++ b/dotnet/entrypoint.sh @@ -9,7 +9,7 @@ export INTERNAL_IP export DOTNET_ROOT=/usr/share/ # print the dotnet version on startup -printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mdotnet --version\n" +printf "\033[1m\033[33mcontainer~ \033[0mdotnet --version\n" dotnet --version # Replace Startup Variables diff --git a/erlang/entrypoint.sh b/erlang/entrypoint.sh index 5ce5cae..a227442 100644 --- a/erlang/entrypoint.sh +++ b/erlang/entrypoint.sh @@ -10,7 +10,7 @@ export INTERNAL_IP cd /home/container || exit 1 # Print Erlang's version -printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0merl -noshell -eval 'erlang:display(erlang:system_info(system_version))' -eval 'init:stop()'\n" +printf "\033[1m\033[33mcontainer~ \033[0merl -noshell -eval 'erlang:display(erlang:system_info(system_version))' -eval 'init:stop()'\n" erl -noshell -eval 'erlang:display(erlang:system_info(system_version))' -eval 'init:stop()' # Convert all of the "{{VARIABLE}}" parts of the command into the expected shell @@ -19,7 +19,7 @@ erl -noshell -eval 'erlang:display(erlang:system_info(system_version))' -eval 'i PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') # Display the command we're running in the output, and then execute it with eval -printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m" +printf "\033[1m\033[33mcontainer~ \033[0m" echo "$PARSED" # shellcheck disable=SC2086 eval "$PARSED" diff --git a/games/minetest/entrypoint.sh b/games/minetest/entrypoint.sh index 399eb5a..2b8769d 100644 --- a/games/minetest/entrypoint.sh +++ b/games/minetest/entrypoint.sh @@ -12,7 +12,7 @@ export INTERNAL_IP cd /home/container || exit 1 # Print minetest version -printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mminetest --version\n" +printf "\033[1m\033[33mcontainer~ \033[0mminetest --version\n" minetest --version # Replace Startup Variables @@ -20,4 +20,4 @@ MODIFIED_STARTUP=$(echo -e ${STARTUP} | sed -e 's/{{/${/g' -e 's/}}/}/g') echo -e ":/home/container$ ${MODIFIED_STARTUP}" # Run the Server -eval ${MODIFIED_STARTUP} \ No newline at end of file +eval ${MODIFIED_STARTUP} diff --git a/go/entrypoint.sh b/go/entrypoint.sh index e9c7a62..ce4bab9 100644 --- a/go/entrypoint.sh +++ b/go/entrypoint.sh @@ -34,7 +34,7 @@ export INTERNAL_IP cd /home/container || exit 1 # Print Go version -printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mgo version\n" +printf "\033[1m\033[33mcontainer~ \033[0mgo version\n" go version # Convert all of the "{{VARIABLE}}" parts of the command into the expected shell @@ -43,7 +43,7 @@ go version PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') # Display the command we're running in the output, and then execute it with eval -printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m" +printf "\033[1m\033[33mcontainer~ \033[0m" echo "$PARSED" # shellcheck disable=SC2086 eval "$PARSED" diff --git a/java/entrypoint.sh b/java/entrypoint.sh index 25e5f5c..bad5576 100755 --- a/java/entrypoint.sh +++ b/java/entrypoint.sh @@ -34,7 +34,7 @@ export INTERNAL_IP cd /home/container || exit 1 # Print Java version -printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mjava -version\n" +printf "\033[1m\033[33mcontainer~ \033[0mjava -version\n" java -version # Convert all of the "{{VARIABLE}}" parts of the command into the expected shell @@ -43,7 +43,7 @@ java -version PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') # Display the command we're running in the output, and then execute it with eval -printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m" +printf "\033[1m\033[33mcontainer~ \033[0m" echo "$PARSED" # shellcheck disable=SC2086 eval "$PARSED" diff --git a/oses/alpine/entrypoint.sh b/oses/alpine/entrypoint.sh index 070cd85..261a108 100644 --- a/oses/alpine/entrypoint.sh +++ b/oses/alpine/entrypoint.sh @@ -37,7 +37,7 @@ cd /home/container || exit 1 PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') # Display the command we're running in the output, and then execute it with eval -printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m" +printf "\033[1m\033[33mcontainer~ \033[0m" echo "$PARSED" # shellcheck disable=SC2086 eval "$PARSED" diff --git a/python/entrypoint.sh b/python/entrypoint.sh index 978b2a1..235d6bf 100644 --- a/python/entrypoint.sh +++ b/python/entrypoint.sh @@ -14,7 +14,7 @@ python --version PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') # Display the command we're running in the output, and then execute it with eval -printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m" +printf "\033[1m\033[33mcontainer~ \033[0m" echo "$PARSED" # shellcheck disable=SC2086 eval "$PARSED" diff --git a/voice/teaspeak/entrypoint.sh b/voice/teaspeak/entrypoint.sh index b71bd42..429f864 100644 --- a/voice/teaspeak/entrypoint.sh +++ b/voice/teaspeak/entrypoint.sh @@ -18,7 +18,7 @@ echo "installed youtube-dl Version:" PARSED=$(echo "$STARTUP" | sed -e 's/{{/${/g' -e 's/}}/}/g') # Display the command we're running in the output, and then execute it with eval -printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m" +printf "\033[1m\033[33mcontainer~ \033[0m" echo "$PARSED" # shellcheck disable=SC2086 eval "$PARSED"