Let say I am copying files in a Dockerfile. For example, I am copying a file called config.txt.
What is the best way, to copy a new config.txt file from the docker stack command, that will thus change the existing config.txt file that wass copied from the Dockerfile?
Is using a volume in the stack file the best practice ?
Dockerfile
FROM ubuntu:18.04
COPY ./configs /app/configs
RUN make /app
CMD python /app/app.py
stack.yml
version: '3.1'
services:
python-app
image: url:image
volumes:
- ./configs/config.txt:/app/configs // modify the existing config.txt file
...