2
2
mirror of https://github.com/octoleo/restic.git synced 2024-12-22 10:58:55 +00:00
restic/docker/Dockerfile.release
2023-07-08 23:05:02 +02:00

21 lines
524 B
Docker

FROM --platform=$BUILDPLATFORM alpine:latest as helper
ARG VERSION
ARG TARGETOS
ARG TARGETARCH
# add release binary for the appropriate platform
COPY restic_${VERSION}_${TARGETOS}_${TARGETARCH}.bz2 /
RUN apk add --update --no-cache bzip2
RUN set -e && \
bzcat restic_${VERSION}_${TARGETOS}_${TARGETARCH}.bz2 > restic && \
chmod +x restic
FROM alpine:latest
COPY --from=helper /restic /usr/bin
RUN apk add --update --no-cache ca-certificates fuse openssh-client tzdata jq
ENTRYPOINT ["/usr/bin/restic"]