Being quite new to Docker, I would like to ask about something that appears to be superfluous to me in the official Django docs.
The last line of the Dockerfile is:
COPY . /code/
But in the docker-compose.yml file, we have this statement:
volumes:
- .:/code
Is the first part not superfluous if the second part exists? Does it not simply make the image larger, without serving a purpose since the content of the folder gets overwritten by the mount anyway?
Hello,
Being quite new to Docker, I would like to ask about something that appears to be superfluous to me in the official Django docs.
The last line of the Dockerfile is:
COPY . /code/
But in the docker-compose.yml file, we have this statement:
Is the first part not superfluous if the second part exists? Does it not simply make the image larger, without serving a purpose since the content of the folder gets overwritten by the mount anyway?
Or am I missing something?