My understanding is that the gemfile in a Rails app only provides references to the actual code of these gems on your local computer. So when you're running your app locally, it's pulling the gem code from your local computer. What happens when you deploy though? The server runs your rails code, but does it also hold all the references in your gem file and automatically download them as well?
Asked
Active
Viewed 364 times
3
-
1Possible duplicate of [How can I find where gem files are installed?](http://stackoverflow.com/questions/19072070/how-can-i-find-where-gem-files-are-installed) – shirajg Jan 13 '17 at 21:16
2 Answers
1
Yep. If you deploy on Heroku, you can see bundler doing its work and pulling down the gems.

jvillian
- 19,953
- 5
- 31
- 44
1
As per the Bundler docs, you can use bundle show --paths
to see exactly where your gems are being loaded from.
Additionally, if you aren't using bundler, you can use the command gem environment
to see gem paths on the system.
See this existing answer for more info: How can I find where gem files are installed?
-
1yes i know they are loaded from the computer somewhere, but my question was asking if it's the same when they get deployed to a server. As in, does the server hold similar paths as well – stackjlei Jan 13 '17 at 22:00
-
1@stackjlei If you start a console on your server, and issue the commands, you should see the paths to the gems on the server. – shirajg Jan 13 '17 at 22:04