Chris24680 PRO
Joined 5/19/2021
Chris24680 PRO said about 2 years ago on Docker on Rails 7 :
I'm having an odd issue here where if I add a gem to my app, I then am unable to start up the docker container for example, I run:
bundle add better_errors
I then close down the docker container and start it back up and I get:
ppm-app-1       | Could not find better_errors-2.9.1, coderay-1.1.3 in any of the sources                                                      
ppm-app-1       | Run `bundle install` to install missing gems.                                                                                
ppm-app-1 exited with code 7
The app then won't start up until I remove the gem from my gem file?

Chris24680 PRO said about 2 years ago on Docker on Rails 7 :
Yup if I runĀ 
docker compose run --rm app bundle install
Then the gem installs in the container and I'm able to start the app. Though I thought the bundle volume would mean I wouldn't have to do that? Or am I misunderstanding?

Chris24680 PRO said about 2 years ago on Docker on Rails 7 :
Ah I thinkĀ  I know what the issue might be. My host has RVM installed, so my gems aren't installed in /usr/local/bundle, they're installed in .rvm/gems/ruby-3.1.0/gems/. Would there be any way around this?