This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
services: | |
web: | |
build: . | |
volumes: | |
- sample_volume/:/app/dummy/ | |
volumes: | |
sample_volume: | |
external: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM python:3 | |
WORKDIR /app | |
COPY . . | |
RUN mkdir dummy && cd dummy && touch a.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#(FROM python:3 is parent of WORKDIR /app i.e below instruction) | |
FROM python:3 | |
#(WORKDIR /app is child of FROM python:3 i.e. above instruction) | |
WORKDIR /app | |
COPY . . | |
RUN pip install -r requirements.txt | |
RUN chmod +x /app/start.sh | |
ENTRYPOINT ["/bin/bash", "/app/start.sh"] |