Make Dockerfile Deploy faster by structuring your Dockerfile to maximize efficiency by leveraging the Docker build cache:Documentation Index
Fetch the complete documentation index at: https://www.aptible.com/docs/llms.txt
Use this file to discover all available pages before exploring further.
Gems installed via Bundler
In order for the Docker build cache to cache gems installed via Bundler:- Add the Gemfile and Gemfile.lock files to the image.
-
Run
bundle install, before adding the rest of the repo (viaADD .).
Packages installed via NPM
In order for the Docker build cache to cache packages installed via npm:-
Add the
package.jsonfile to the image. -
Run
npm install, before adding the rest of the repo (viaADD .).
Packages installed via PIP
In order for the Docker build cache to cache packages installed via pip:-
Add the
requirements.txtfile to the image. -
Run
pip install, before adding the rest of the repo (viaADD .).

