Question: Learn / Courses / Introduction to Docker Exercise Ordering Dockerfile instructions When writing Dockerfiles, the order of your Dockerfile instructions determines how long the build

Learn / Courses / Introduction to Docker
Exercise
Ordering Dockerfile instructions
When writing Dockerfiles, the order of your Dockerfile instructions determines how long the build will take after updating any of the commands. Do you understand how to make the most efficient Dockerfiles?
Drag the items below into order
Instructions
100P
Order the Dockerfile instructions to the order in which you are most likely able to re-use as many cached layers as possible.
From how we typically work, we know that the packages we need for our pipeline, defined in requirements.txt, change less often than the python code in
pipeline.py .
COPY /app/requirements.txt /app/requirements.txt
COPY /app/pipeline.py /app/pipeline.py
FROM
docker.io/library/ubuntu
RUN apt-get install -y python 3
RUN apt-get update
 Learn / Courses / Introduction to Docker Exercise Ordering Dockerfile instructions

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!