Files
protonmail-bridge/build/Dockerfile
T
GitHub Actions 2ca2b80ff4
Build and Push Docker Container / build-and-push (push) Successful in 5m50s
cleanup entrypoint.sh and add haveged for getentropy
2026-03-11 09:30:04 +01:00

46 lines
1.0 KiB
Docker

FROM golang:alpine AS build
ARG VERSION
RUN apk add --no-cache pass gcc musl-dev git make \
libsecret-dev \
libfido2-dev \
libcbor-dev
# Build
ADD https://github.com/ProtonMail/proton-bridge.git#${VERSION} /build/proton-bridge/
WORKDIR /build/proton-bridge/
RUN sed -i 's/127.0.0.1/0.0.0.0/g' internal/constants/constants.go
RUN make build-nogui vault-editor
FROM alpine:latest
EXPOSE 1025/tcp
EXPOSE 1143/tcp
RUN mkdir -p /root/.gnupg && chmod 700 /root/.gnupg
# Install dependencies and protonmail bridge
RUN apk add --no-cache \
gcompat \
libsecret \
libfido2 \
gnupg \
pass \
ca-certificates \
dbus \
dbus-x11 \
gnome-keyring \
haveged
# Copy bash scripts
COPY gpgparams entrypoint.sh /protonmail/
WORKDIR /protonmail/
# Copy protonmail
COPY --from=build /build/proton-bridge/bridge /usr/bin/
COPY --from=build /build/proton-bridge/proton-bridge /usr/bin/
COPY --from=build /build/proton-bridge/vault-editor /usr/bin/
ENTRYPOINT ["bash", "/protonmail/entrypoint.sh"]