17863: update to using bundler 2.2.19 everywhere.
[arvados.git] / build / rails-package-scripts / postinst.sh
index 3eb2d2c5e0c2f58d2099f131c0b3ecd0d8e3078b..5eb69d08105e370cdf6b27a157617c33d47d3194 100644 (file)
@@ -199,7 +199,7 @@ configure_version() {
   export RAILS_ENV=production
 
   if ! $COMMAND_PREFIX bundle --version >/dev/null; then
-      run_and_report "Installing bundler" $COMMAND_PREFIX gem install bundler --version 1.17.3
+      run_and_report "Installing bundler" $COMMAND_PREFIX gem install bundler --version 2.2.19
   fi
 
   run_and_report "Running bundle install" \
@@ -226,19 +226,15 @@ configure_version() {
       prepare_database
   fi
 
-  if [ 11 = "$RAILSPKG_SUPPORTS_CONFIG_CHECK$APPLICATION_READY" ]; then
+  if [ -e /etc/arvados/config.yml ]; then
+      # warn about config errors (deprecated/removed keys from
+      # previous version, etc)
       run_and_report "Checking configuration for completeness" \
-          $COMMAND_PREFIX bundle exec rake config:check || APPLICATION_READY=0
-  fi
-
-  # precompile assets; thankfully this does not take long
-  if [ "$APPLICATION_READY" = "1" ]; then
-      run_and_report "Precompiling assets" \
-          $COMMAND_PREFIX bundle exec rake assets:precompile -q -s 2>/dev/null \
-          || APPLICATION_READY=0
+                     $COMMAND_PREFIX bundle exec rake config:check || APPLICATION_READY=0
   else
-      echo "Precompiling assets... skipped."
+      APPLICATION_READY=0
   fi
+
   chown -R "$WWW_OWNER:" $RELEASE_PATH/tmp
 
   setup_before_nginx_restart