forked from getsops/sops
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Alpine-based docker image (getsops#609)
* Add Dockerfile.alpine * Publish alpine containers as "mozilla/sops:vX.X.X-alpine", "mozilla/sops:vX.X-alpine", "mozilla/sops:vX-alpine", and "mozilla/sops:alpine"
- Loading branch information
1 parent
54beb9e
commit 9064c07
Showing
3 changed files
with
35 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
/.git | ||
/Dockerfile | ||
/Dockerfile.alpine |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
FROM golang:1.12-alpine3.10 AS builder | ||
|
||
RUN apk --no-cache add make | ||
|
||
COPY . /go/src/go.mozilla.org/sops | ||
WORKDIR /go/src/go.mozilla.org/sops | ||
|
||
RUN CGO_ENABLED=1 make install | ||
|
||
|
||
FROM alpine:3.10 | ||
|
||
RUN apk --no-cache add \ | ||
vim ca-certificates | ||
ENV EDITOR vim | ||
COPY --from=builder /go/bin/sops /usr/local/bin/sops | ||
ENTRYPOINT ["/usr/local/bin/sops"] |