-
-
Save jesbrd/1d48083f2eb459f5074d412603883919 to your computer and use it in GitHub Desktop.
Docker image entrypoint idle script
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo "This is a idle script (infinite loop) to keep container running." | |
echo "Please replace this script." | |
cleanup () | |
{ | |
kill -s SIGTERM $! | |
exit 0 | |
} | |
trap cleanup SIGINT SIGTERM | |
while [ 1 ] | |
do | |
sleep 60 & | |
wait $! | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment