add certificates

This commit is contained in:
tokibi 2020-12-16 20:12:21 +09:00 committed by Lena Fuhrimann
parent a91674ff0f
commit 506487e3e2

View file

@ -4,11 +4,12 @@ WORKDIR /app
COPY . ./ COPY . ./
RUN CGO_ENABLED=0 go build -ldflags="-s -w" -a -installsuffix cgo -o bin/s3manager ./cmd/s3manager RUN CGO_ENABLED=0 go build -ldflags="-s -w" -a -installsuffix cgo -o bin/s3manager ./cmd/s3manager
FROM scratch FROM alpine
WORKDIR /app WORKDIR /app
COPY --from=builder /app/bin/s3manager ./ COPY --from=builder /app/bin/s3manager ./
COPY --from=builder /app/web ./web/ COPY --from=builder /app/web ./web/
COPY --from=builder /etc/passwd /etc/passwd COPY --from=builder /etc/passwd /etc/passwd
RUN apk update && apk add --no-cache ca-certificates
USER app USER app
EXPOSE 8080 EXPOSE 8080
ENTRYPOINT ["./s3manager"] ENTRYPOINT ["./s3manager"]