restic/docker/Dockerfile

19 lines
375 B
Docker
Raw Normal View History

FROM golang:1.22-alpine AS builder
2017-06-23 10:26:51 +02:00
2021-09-20 14:18:48 +02:00
WORKDIR /go/src/github.com/restic/restic
# Caching dependencies
COPY go.mod go.sum ./
RUN go mod download
COPY . .
RUN go run build.go
FROM alpine:latest AS restic
2017-06-23 10:26:51 +02:00
RUN apk add --no-cache ca-certificates fuse openssh-client tzdata jq
2017-06-23 10:38:19 +02:00
2021-09-20 14:18:48 +02:00
COPY --from=builder /go/src/github.com/restic/restic/restic /usr/bin
2017-06-23 10:26:51 +02:00
ENTRYPOINT ["/usr/bin/restic"]