add Dockerfile

This commit is contained in:
Seán C McCord 2023-03-05 10:57:04 -05:00
commit dff1f5b977
No known key found for this signature in database
GPG key ID: 0BE02ACD7471B0E8

27
Dockerfile Normal file
View file

@ -0,0 +1,27 @@
FROM golang:1.19 AS builder
RUN apt-get update && \
apt-get install -y --no-install-recommends pass libsecret-1-dev && \
rm -Rf /var/lib/apt/list/*
ENV VERSION=v3.0.18
WORKDIR /build
RUN git clone -b $VERSION https://github.com/ProtonMail/proton-bridge.git
WORKDIR /build/proton-bridge
RUN make build-nogui
FROM debian
RUN apt-get update && \
apt-get install -y --no-install-recommends pass libsecret-1-0 && \
rm -Rf /var/lib/apt/list/*
COPY --from=builder /build/proton-bridge/bridge /usr/local/bin/
COPY --from=builder /build/proton-bridge/proton-bridge /usr/local/bin/
ENTRYPOINT ["/usr/local/bin/proton-bridge"]
CMD ["--noninteractive"]