Skip to content

Commit 1c8008e

Browse files
committed
feat: Dockerfiles for prod
1 parent 132a89b commit 1c8008e

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

Dockerfile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,14 @@ RUN pip install pdm
99

1010
# copy files
1111
COPY pyproject.toml pdm.lock README.md /project/
12-
COPY data/ project/data
13-
COPY src/ /project/src
12+
COPY . /project/
1413

1514

1615
WORKDIR /project
1716

1817
RUN pdm install
18+
RUN chmod +x docker-entrypoint.sh
19+
1920

2021
EXPOSE 8080
2122
CMD ["pdm", "run", "start"]

docker-compose.yaml

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
1-
version: '3.8'
2-
31
services:
42
myapp:
5-
build:
6-
context: .
7-
target: builder
3+
image: mrsunglasses/pastepy:latest
4+
env_file:
5+
- .env
86
ports:
9-
- "8080:8080"
10-
command: ["pdm", "run", "start"]
7+
- "8082:8080"
8+
entrypoint: ["./docker-entrypoint.sh"]
9+
command: ["pdm", "run", "start"]

0 commit comments

Comments
 (0)