Skip to content

Commit

Permalink
remove not needed entry points.. make sure credentials stay even afte…
Browse files Browse the repository at this point in the history
…r restarts
  • Loading branch information
Test committed Sep 20, 2024
1 parent b27ac5e commit fedc8d6
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 40 deletions.
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.0.19-alpha
1.0.20-alpha
1 change: 0 additions & 1 deletion config/credentials.yml.enc

This file was deleted.

13 changes: 11 additions & 2 deletions entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,24 @@ if [ -z "$SECRET_KEY_BASE" ]; then
export SECRET_KEY_BASE=$(bin/rails secret)
fi

echo "Running bundle exec rake assets:precompile"
if [ -f storage/credentials.yml.enc ]; then
if [ ! -f config/credentials.yml.enc ]; then
cp storage/credentials.yml.enc config/credentials.yml.enc
fi
else
EDITOR=sed rails credentials:edit --environment production
cp config/credentials.yml.enc storage/credentials.yml.enc
fi


echo "Remove PID"
rm -f /app/tmp/pids/server.pid
echo "Running bundle exec rake assets:precompile"
bundle exec rake assets:precompile RAILS_ENV=production
echo "Running bundle exec rails db:migrate RAILS_ENV=production"
bundle exec rails db:migrate RAILS_ENV=production

# Start Sidekiq worker in the background
./sidekiq-entrypoint.sh &
bundle exec sidekiq &


Expand Down
21 changes: 0 additions & 21 deletions rails-entrypoint.sh

This file was deleted.

15 changes: 0 additions & 15 deletions sidekiq-entrypoint.sh

This file was deleted.

0 comments on commit fedc8d6

Please sign in to comment.