Skip to content

Commit fde4791

Browse files
build: add Dockerfile
1 parent 8088d96 commit fde4791

File tree

3 files changed

+126
-0
lines changed

3 files changed

+126
-0
lines changed

.github/workflows/ci.yml

+2
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,5 @@ jobs:
2323
run: mypy oc4ids_datastore_api/ tests/
2424
- name: Run tests
2525
run: pytest
26+
- name: Build docker image
27+
run: docker build -t oc4ids-datastore-api .

Dockerfile

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
FROM python:3.12-slim
2+
3+
RUN apt-get update \
4+
&& apt-get install -y libpq-dev gcc
5+
6+
WORKDIR /oc4ids_datastore_api
7+
8+
COPY requirements.txt .
9+
10+
RUN pip install -r requirements.txt
11+
12+
COPY . .
13+
14+
RUN pip install .
15+
16+
EXPOSE 8000
17+
18+
ENTRYPOINT ["fastapi", "run", "oc4ids_datastore_api/main.py"]

requirements.txt

+106
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,106 @@
1+
#
2+
# This file is autogenerated by pip-compile with Python 3.12
3+
# by the following command:
4+
#
5+
# pip-compile --output-file=requirements.txt pyproject.toml
6+
#
7+
annotated-types==0.7.0
8+
# via pydantic
9+
anyio==4.8.0
10+
# via
11+
# httpx
12+
# starlette
13+
# watchfiles
14+
certifi==2025.1.31
15+
# via
16+
# httpcore
17+
# httpx
18+
click==8.1.8
19+
# via
20+
# rich-toolkit
21+
# typer
22+
# uvicorn
23+
dnspython==2.7.0
24+
# via email-validator
25+
email-validator==2.2.0
26+
# via fastapi
27+
fastapi[standard]==0.115.8
28+
# via oc4ids-datastore-api (pyproject.toml)
29+
fastapi-cli[standard]==0.0.7
30+
# via fastapi
31+
h11==0.14.0
32+
# via
33+
# httpcore
34+
# uvicorn
35+
httpcore==1.0.7
36+
# via httpx
37+
httptools==0.6.4
38+
# via uvicorn
39+
httpx==0.28.1
40+
# via fastapi
41+
idna==3.10
42+
# via
43+
# anyio
44+
# email-validator
45+
# httpx
46+
jinja2==3.1.5
47+
# via fastapi
48+
markdown-it-py==3.0.0
49+
# via rich
50+
markupsafe==3.0.2
51+
# via jinja2
52+
mdurl==0.1.2
53+
# via markdown-it-py
54+
psycopg2==2.9.10
55+
# via oc4ids-datastore-api (pyproject.toml)
56+
pydantic==2.10.6
57+
# via
58+
# fastapi
59+
# sqlmodel
60+
pydantic-core==2.27.2
61+
# via pydantic
62+
pygments==2.19.1
63+
# via rich
64+
python-dotenv==1.0.1
65+
# via uvicorn
66+
python-multipart==0.0.20
67+
# via fastapi
68+
pyyaml==6.0.2
69+
# via uvicorn
70+
rich==13.9.4
71+
# via
72+
# rich-toolkit
73+
# typer
74+
rich-toolkit==0.13.2
75+
# via fastapi-cli
76+
shellingham==1.5.4
77+
# via typer
78+
sniffio==1.3.1
79+
# via anyio
80+
sqlalchemy==2.0.38
81+
# via sqlmodel
82+
sqlmodel==0.0.22
83+
# via oc4ids-datastore-api (pyproject.toml)
84+
starlette==0.45.3
85+
# via fastapi
86+
typer==0.15.1
87+
# via fastapi-cli
88+
typing-extensions==4.12.2
89+
# via
90+
# anyio
91+
# fastapi
92+
# pydantic
93+
# pydantic-core
94+
# rich-toolkit
95+
# sqlalchemy
96+
# typer
97+
uvicorn[standard]==0.34.0
98+
# via
99+
# fastapi
100+
# fastapi-cli
101+
uvloop==0.21.0
102+
# via uvicorn
103+
watchfiles==1.0.4
104+
# via uvicorn
105+
websockets==14.2
106+
# via uvicorn

0 commit comments

Comments
 (0)