aboutsummaryrefslogtreecommitdiff
path: root/scripts/upgrade
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/upgrade')
-rw-r--r--scripts/upgrade16
1 files changed, 8 insertions, 8 deletions
diff --git a/scripts/upgrade b/scripts/upgrade
index 2914550..895049b 100644
--- a/scripts/upgrade
+++ b/scripts/upgrade
@@ -284,14 +284,14 @@ chown -R "$app": "$final_path"
pushd "$final_path/live"
ynh_use_nodejs
- bundle config deployment 'true'
- bundle config without 'development test'
- bundle install -j$(getconf _NPROCESSORS_ONLN)
- yarn install --pure-lockfile
- RAILS_ENV=production bundle exec rails assets:clean
- RAILS_ENV=production bundle exec rails assets:precompile
- RAILS_ENV=production bundle exec rails db:migrate
- RAILS_ENV=production bin/tootctl cache clear
+ sudo -u $app PATH=$PATH $RBENV_ROOT/shims/bundle config deployment 'true'
+ sudo -u $app PATH=$PATH $RBENV_ROOT/shims/bundle config without 'development test'
+ sudo -u $app PATH=$PATH $RBENV_ROOT/shims/bundle install -j$(getconf _NPROCESSORS_ONLN)
+ sudo -u $app PATH=$PATH yarn install --pure-lockfile
+ sudo -u $app RAILS_ENV=production PATH=$PATH bin/bundle exec rails assets:clean
+ sudo -u $app RAILS_ENV=production PATH=$PATH bin/bundle exec rails assets:precompile
+ sudo -u $app RAILS_ENV=production PATH=$PATH bin/bundle exec rails db:migrate
+ sudo -u $app RAILS_ENV=production PATH=$PATH bin/tootctl cache clear
popd
# Recalculate and store the checksum of the file for the next upgrade.