forked from kevinpt/symbolator
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Dockerfile
43 lines (31 loc) · 1.18 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
## Symbolator
FROM ubuntu:latest AS build-symbolator
# Build from forked source because upstream is broken for the latest python3 versions
RUN apt-get update && apt-get install --no-install-recommends --yes \
git \
pip \
python3-dev \
patchelf \
python3-gi-cairo \
python3-gi \
build-essential \
libpango1.0-dev && \
apt-get clean && apt-get autoremove
# Install latest pip and setuptools
RUN python3 -m pip install --upgrade pip setuptools
RUN python3 -m pip install --upgrade nuitka
WORKDIR /build
ADD . /src
# Install symbolator
RUN python3 -m pip install --upgrade /src
# Use nuitka to compile a static binary so we dont need python in the final image
RUN python3 -m nuitka --onefile /usr/local/bin/symbolator --include-module=gi.overrides.Pango --include-module=gi._gi_cairo
FROM ubuntu:latest AS main
RUN apt-get update && apt-get install --no-install-recommends --yes \
libpango1.0 && \
apt-get clean && apt-get autoremove
COPY --from=build-symbolator /build/symbolator.bin /usr/bin/symbolator
ADD https://github.com/krallin/tini/releases/download/v0.19.0/tini /tini
RUN chmod +x /tini
ENTRYPOINT ["/tini", "--", "/usr/bin/symbolator"]
WORKDIR /src