2021-04-22 10:57:34 +00:00
|
|
|
ARG base_image=ubuntu:20.04
|
|
|
|
FROM $base_image as build
|
2021-04-11 19:45:59 +00:00
|
|
|
ENV PYTHONUNBUFFERED=1
|
|
|
|
ENV LC_ALL C.UTF-8
|
|
|
|
ENV DEBIAN_FRONTEND noninteractive
|
|
|
|
|
|
|
|
# Make apt faster
|
|
|
|
RUN echo force-unsafe-io > /etc/dpkg/dpkg.cfg.d/docker-apt-speedup
|
|
|
|
RUN echo "Dpkg::Use-Pty=0;" > /etc/apt/apt.conf.d/99quieter
|
|
|
|
|
|
|
|
RUN apt-get update -qq
|
|
|
|
RUN apt-get install -y -qq \
|
2021-04-13 21:17:17 +00:00
|
|
|
python3-pip \
|
2021-04-14 11:26:50 +00:00
|
|
|
openvpn \
|
|
|
|
strongswan
|
2021-04-11 19:45:59 +00:00
|
|
|
|
2021-04-14 11:26:50 +00:00
|
|
|
COPY entrypoint-openvpn.sh /entrypoint-openvpn.sh
|
|
|
|
COPY entrypoint-strongswan.sh /entrypoint-strongswan.sh
|
2021-04-11 19:45:59 +00:00
|
|
|
COPY pinecrypt/client/. /src/pinecrypt/client
|
|
|
|
COPY setup.py /src/
|
|
|
|
COPY README.md /src/
|
|
|
|
COPY misc/ /src/misc/
|
|
|
|
WORKDIR /src
|
|
|
|
RUN pip3 install .
|
2021-04-13 21:17:17 +00:00
|
|
|
RUN echo "#!/bin/sh" > /usr/bin/chcon
|
|
|
|
RUN chmod +x /usr/bin/chcon
|