-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
65 lines (52 loc) · 1.49 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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
FROM pcr.teskalabs.com/alpine:3.18 AS building
MAINTAINER TeskaLabs Ltd ([email protected])
# Include build environment variables from GitLab CI/CD
ARG CI_COMMIT_BRANCH
ARG CI_COMMIT_TAG
ARG CI_COMMIT_REF_NAME
ARG CI_COMMIT_SHA
ARG CI_COMMIT_TIMESTAMP
ARG CI_JOB_ID
ARG CI_PIPELINE_CREATED_AT
ARG CI_RUNNER_ID
ARG CI_RUNNER_EXECUTABLE_ARCH
ARG GITHUB_HEAD_REF
ARG GITHUB_JOB
ARG GITHUB_SHA
ARG GITHUB_REPOSITORY
ENV LANG C.UTF-8
RUN set -ex \
&& apk update \
&& apk upgrade
RUN apk add --no-cache \
git \
python3-dev \
py3-pip \
libffi-dev \
openssl-dev \
libgit2-dev \
gcc \
g++ \
musl-dev \
freetype-dev \
cairo-dev
RUN pip3 install --upgrade pip
RUN pip3 install --no-cache-dir pygit2==1.11 aiokafka aiosmtplib fastjsonschema
RUN pip3 install --no-cache-dir jinja2 markdown pyyaml xhtml2pdf git+https://github.com/TeskaLabs/asab.git
RUN pip3 install --no-cache-dir sentry-sdk slack_sdk pytz
RUN mkdir -p /app/asab-iris
COPY . /app/asab-iris
FROM pcr.teskalabs.com/alpine:3.18 AS shiping
RUN apk add --no-cache \
python3 \
libgit2
COPY --from=building /usr/lib/python3.11/site-packages /usr/lib/python3.11/site-packages
COPY ./asabiris /app/asab-iris/asabiris
COPY ./asab-iris.py /app/asab-iris/asab-iris.py
COPY ./library /app/asab-iris/library
COPY ./CHANGELOG.md /app/asab-iris/CHANGELOG.md
RUN set -ex \
&& mkdir /conf \
&& touch conf/asab-iris.conf
WORKDIR /app/asab-iris
CMD ["python3", "asab-iris.py", "-c", "/conf/asab-iris.conf"]