forked from yandex/ch-backup
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile-deb-build
More file actions
46 lines (41 loc) · 1.28 KB
/
Dockerfile-deb-build
File metadata and controls
46 lines (41 loc) · 1.28 KB
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
ARG BASE_IMAGE=ubuntu:22.04
FROM --platform=$TARGETPLATFORM $BASE_IMAGE
ARG DEBIAN_FRONTEND=noninteractive
RUN set -ex \
&& apt-get update \
&& apt-get install -y --no-install-recommends \
# Debian packaging tools
build-essential \
debhelper \
devscripts \
fakeroot \
# Managing keys for debian package signing
gpg \
gpg-agent \
# Python packaging tools
python3-dev \
python3-pip \
python3-setuptools \
python3-venv \
# Misc
curl \
locales \
# For building PyNacl library
libffi-dev libssl-dev libboost-all-dev libsodium-dev \
# Configure locales
&& locale-gen en_US.UTF-8 \
&& update-locale LANG=en_US.UTF-8 \
# Ensure that `python` refers to `python3`
&& ln -sf /usr/bin/python3 /usr/bin/python \
# Install `uv`
&& python3 -m pip install --upgrade pip \
&& python3 -m pip install uv \
&& ln -sf /usr/local/bin/uv /usr/bin/uv
# Project directory must be mounted here
VOLUME /src
WORKDIR /src
# For compiling PyNACL library, which is used by ch-backup
# See https://pynacl.readthedocs.io/en/latest/install/#linux-source-build
ENV SODIUM_INSTALL=system
ENV PYTHON=/usr/bin/python3
CMD ["make", "build-deb-package-local"]