Skip to content

Commit f5a4abd

Browse files
committed
Revert "Test deploy with dockerfile"
This reverts commit f51ae65.
1 parent f51ae65 commit f5a4abd

File tree

2 files changed

+22
-1
lines changed

2 files changed

+22
-1
lines changed

Dockerfile

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
FROM python:3.11-slim
2+
3+
RUN apt-get update && apt-get install postgresql-client cmake -y
4+
5+
# install PDM
6+
RUN pip install -U pip setuptools wheel
7+
RUN pip install pdm
8+
9+
# copy files
10+
COPY pyproject.toml pdm.lock /project/
11+
COPY . /project
12+
13+
WORKDIR /project
14+
# TODO: improve caching
15+
16+
RUN pdm install --prod --no-lock --no-editable -v
17+
18+
RUN SECRET_KEY=secret pdm run python manage.py collectstatic --noinput
19+
20+
EXPOSE 8080
21+
22+
CMD ["pdm", "server"]

pyproject.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ dev = [
3636
[tool.pdm.scripts]
3737
dev.env = { "GITHUB_TOKEN" = "demo", "SKIP_TOKEN_CHECK" = "true" }
3838
dev.cmd = "python main.py --reload"
39-
server = "uvicorn main:app --reload --port 8080 --host 0.0.0.0"
4039

4140
[tool.pdm.build]
4241
includes = []

0 commit comments

Comments
 (0)