How can I copy installed gems from between Docker stages?

I have a Dockerfile which I’m trying to make multi-staged. It looks something like this: FROM <image> AS build-step RUN bundle install FROM <image> COPY –from=build-step $BUNDLE_INSTALL_PATH ./ Now I’m not sure what to use for the BUNDLE_INSTALL_PATH. What’s the cleanest way to copy over bundle installs from one stage to another? Source: Docker Questions

By Zahin Zaman
Categorised as bundler, docker, dockerfile, ruby, rubygems Tagged , , , ,

Still Have Questions?

Our dedicated development team is here for you!

We can help you find answers to your question for as low as 5$.

Contact Us