Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modified personal message and written commands in Dockerfile. #9

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

abhishek-dhanraj-TI
Copy link

No description provided.


# Install Python requirements using Pip.
RUN pip install -r requirements.txt
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your Dockerfile is fine overall. However, it's better practice to install requirements before copying the codebase (by first copying only the requirements.txt file and running pip install).

This is because Docker images are created in layers, with each command being treated as a new layer, and images are cached in a manner so that if you rebuild your Docker image, then the layers can be re-used up until the first point where something in a layer has changed (reference).

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, I got it. I'll make the necessary changes.
Thank you for your explanation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants