-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathDockerfile
49 lines (38 loc) · 1.71 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
FROM python:3.12-alpine AS base
LABEL maintainer="Jan Speckamp <[email protected]>" \
org.opencontainers.image.authors="Jan Speckamp <[email protected]>" \
org.opencontainers.image.url="https://github.com/52North/connected-systems-pygeoapi" \
org.opencontainers.image.version="${VERSION}" \
org.opencontainers.image.vendor="52°North GmbH" \
org.opencontainers.image.licenses="Apache 2.0" \
org.opencontainers.image.ref.name="52north/connected-systems-pygeoapi" \
org.opencontainers.image.title="52°North OGC API Connected Systems" \
org.opencontainers.image.description="Implementation of OGC API Connected Systems"
# alpine is confused where to look for python libraries so we need to support it here
ENV PYTHONPATH=/usr/lib/python3.12/site-packages
ENV PROJ_DIR=/usr
ENV PYTHONUNBUFFERED=1
RUN apk update
RUN apk add gcc musl-dev git proj proj-dev proj-util geos geos-dev py3-numpy py3-shapely py3-shapely-pyc
WORKDIR /app
# Install requirements
COPY requirements.txt .
RUN pip install -r requirements.txt
COPY requirements_nodeps.txt .
RUN pip install --no-deps -r requirements_nodeps.txt
CMD ["hypercorn", "-c", "hypercorn.conf.py", "connected-systems-api/app:APP"]
#FROM base AS toardb
# individual requirements for toardb-provider
#COPY requirements_toardb_csa.txt .
#RUN pip install -r requirements_toardb_csa.txt
# copy application files
#COPY connected-systems-api connected-systems-api
#COPY hypercorn.conf.py .
#FROM base AS hybrid
FROM base
# individual requirements for hybrid-provider
COPY requirements_hybrid_csa.txt .
RUN pip install -r requirements_hybrid_csa.txt
# copy application files
COPY connected-systems-api connected-systems-api
COPY hypercorn.conf.py .