Skip to content

Commit

Permalink
infra: ensure server app containers can restart when OOM killed
Browse files Browse the repository at this point in the history
  • Loading branch information
santiagorodriguez96 committed May 3, 2024
1 parent 2ed6910 commit 144383f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions bin/docker-entrypoint
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
# If running the rails server then create or migrate existing database
if [ "${1}" == "./bin/rails" ] && [ "${2}" == "server" ]; then
./bin/rails db:prepare

file="/rails/tmp/pids/server.pid"
if [ -f "$file" ] ; then
rm "$file"
fi
fi

exec "${@}"

0 comments on commit 144383f

Please sign in to comment.