diff --git a/alpine/entrypoint.sh b/alpine/entrypoint.sh index 7cf5f0f..602caec 100644 --- a/alpine/entrypoint.sh +++ b/alpine/entrypoint.sh @@ -41,5 +41,6 @@ PARSED=$(echo "${STARTUP}" | sed -e 's/{{/${/g' -e 's/}}/}/g' | eval echo "$(cat # Display the command we're running in the output, and then execute it with the env # from the container itself. printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m%s\n" "$PARSED" -exec env "$PARSED" +# shellcheck disable=SC2086 +exec env ${PARSED} diff --git a/games/fivem/entrypoint.sh b/games/fivem/entrypoint.sh index 814aad7..504bf94 100644 --- a/games/fivem/entrypoint.sh +++ b/games/fivem/entrypoint.sh @@ -41,4 +41,5 @@ PARSED=$(echo "${STARTUP}" | sed -e 's/{{/${/g' -e 's/}}/}/g' | eval echo "$(cat # Display the command we're running in the output, and then execute it with the env # from the container itself. printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m%s\n" "$PARSED" -exec env "$PARSED" +# shellcheck disable=SC2086 +exec env ${PARSED} diff --git a/games/source/entrypoint.sh b/games/source/entrypoint.sh index 2438d78..d5cfc60 100644 --- a/games/source/entrypoint.sh +++ b/games/source/entrypoint.sh @@ -41,4 +41,5 @@ PARSED=$(echo "${STARTUP}" | sed -e 's/{{/${/g' -e 's/}}/}/g' | eval echo "$(cat # Display the command we're running in the output, and then execute it with the env # from the container itself. printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m%s\n" "$PARSED" -exec env "$PARSED" +# shellcheck disable=SC2086 +exec env ${PARSED} diff --git a/go/entrypoint.sh b/go/entrypoint.sh index e64cfd6..3e7121a 100644 --- a/go/entrypoint.sh +++ b/go/entrypoint.sh @@ -34,6 +34,7 @@ export INTERNAL_IP cd /home/container || exit 1 # Print Go version +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 @@ -44,4 +45,5 @@ PARSED=$(echo "${STARTUP}" | sed -e 's/{{/${/g' -e 's/}}/}/g' | eval echo "$(cat # Display the command we're running in the output, and then execute it with the env # from the container itself. printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m%s\n" "$PARSED" -exec env "$PARSED" +# shellcheck disable=SC2086 +exec env ${PARSED} diff --git a/java/entrypoint.sh b/java/entrypoint.sh index 1d3de7b..81c3e29 100644 --- a/java/entrypoint.sh +++ b/java/entrypoint.sh @@ -34,6 +34,7 @@ export INTERNAL_IP cd /home/container || exit 1 # Print Java version +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 @@ -44,4 +45,5 @@ PARSED=$(echo "${STARTUP}" | sed -e 's/{{/${/g' -e 's/}}/}/g' | eval echo "$(cat # Display the command we're running in the output, and then execute it with the env # from the container itself. printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m%s\n" "$PARSED" -exec env "$PARSED" +# shellcheck disable=SC2086 +exec env ${PARSED} diff --git a/java/test.sh b/java/test.sh deleted file mode 100644 index 8660c31..0000000 --- a/java/test.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/sh - -STARTUP="./foo.sh -env {{HOME}}" - -PARSED=$(echo "${STARTUP}" | sed -e 's/{{/${/g' -e 's/}}/}/g' | eval echo "$(cat -)") - -printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m%s\n" "$PARSED" -exec env "$PARSED" diff --git a/nodejs/entrypoint.sh b/nodejs/entrypoint.sh index b4f4bbf..7904c58 100644 --- a/nodejs/entrypoint.sh +++ b/nodejs/entrypoint.sh @@ -34,6 +34,7 @@ export INTERNAL_IP cd /home/container || exit 1 # Print Node.js version +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mnode -v\n" node -v # Convert all of the "{{VARIABLE}}" parts of the command into the expected shell @@ -44,4 +45,5 @@ PARSED=$(echo "${STARTUP}" | sed -e 's/{{/${/g' -e 's/}}/}/g' | eval echo "$(cat # Display the command we're running in the output, and then execute it with the env # from the container itself. printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m%s\n" "$PARSED" -exec env "$PARSED" +# shellcheck disable=SC2086 +exec env ${PARSED} diff --git a/python/entrypoint.sh b/python/entrypoint.sh index df6128b..8f009ee 100644 --- a/python/entrypoint.sh +++ b/python/entrypoint.sh @@ -34,12 +34,16 @@ export INTERNAL_IP cd /home/container || exit 1 # Print Python version +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0mpython --version\n" python --version -# Replace variables in the startup command -MODIFIED_STARTUP=$(eval echo "$(echo "${STARTUP}" | sed -e 's/{{/${/g' -e 's/}}/}/g')") -printf '\033[1m\033[33mcontainer@pterodactyl~ \033[0m' -echo "${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' | eval echo "$(cat -)") -# Run the startup command -exec env "${MODIFIED_STARTUP}" +# Display the command we're running in the output, and then execute it with the env +# from the container itself. +printf "\033[1m\033[33mcontainer@pterodactyl~ \033[0m%s\n" "$PARSED" +# shellcheck disable=SC2086 +exec env ${PARSED}