You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In an environment where BUNDLE_APP_CONFIG is set, one set of bundler settings are used to load puma, and then a different set of bundler settings are used when forking off workers. This causes, eg:
> bundle exec puma -C config.rb hello.ru[3026] * Pruning Bundler environment[3026] Puma starting in cluster mode...[3026] * Puma version: 5.4.0 (ruby 2.7.3-p183) ("Super Flight")[3026] * Min threads: 0[3026] * Max threads: 5[3026] * Environment: development[3026] * Master PID: 3026[3026] * Workers: 2[3026] * Restarts: (✔) hot (✔) phased[3026] * Listening on http://0.0.0.0:9292[3026] Use Ctrl-C to stop[3027] + Gemfile in context: /Users/jon/Developer/puma-env/Gemfile[3028] + Gemfile in context: /Users/jon/Developer/puma-env/GemfileCould not find rake-13.0.6 in any of the sourcesCould not find rake-13.0.6 in any of the sourcesRun `bundle install` to install missing gems.Run `bundle install` to install missing gems.[3028] ! Unable to start worker[3027] ! Unable to start worker[3028] /Users/jon/.gem/ruby/2.7.0/gems/bundler-2.2.16/lib/bundler/setup.rb:17:in `exit'[3027] /Users/jon/.gem/ruby/2.7.0/gems/bundler-2.2.16/lib/bundler/setup.rb:17:in `exit'[3028] Early termination of worker[3027] Early termination of worker
I ran into this in a docker project where the base ruby image sets BUNDLE_APP_CONFIG=/usr/local/bundle, but I also happened to have a local .bundle directory which I was using outside of docker.
Describe the bug
In an environment where BUNDLE_APP_CONFIG is set, one set of bundler settings are used to load puma, and then a different set of bundler settings are used when forking off workers. This causes, eg:
I ran into this in a docker project where the base ruby image sets BUNDLE_APP_CONFIG=/usr/local/bundle, but I also happened to have a local .bundle directory which I was using outside of docker.
Puma config:
To Reproduce
There's a reproduction repo here - https://github.com/jdelStrother/puma-vs-bundler
Perhaps Puma::Launcher#prune_bundler could be tweaked to something like:
?
Desktop
The text was updated successfully, but these errors were encountered: