Skip to content

Commit

Permalink
Switch to distroless/static (#107)
Browse files Browse the repository at this point in the history
  • Loading branch information
kgaughan authored Aug 25, 2024
1 parent b60cb64 commit d6e1c2c
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
1 change: 1 addition & 0 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ builds:
mod_timestamp: "{{ .CommitTimestamp }}"
tags:
- netgo
- timetzdata

brews:
- name: planet-mercury
Expand Down
3 changes: 1 addition & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM alpine:latest
FROM gcr.io/distroless/static:latest

LABEL org.opencontainers.image.title=Mercury
LABEL org.opencontainers.image.description="A Planet-style feed aggregator"
Expand All @@ -8,7 +8,6 @@ LABEL org.opencontainers.image.url=https://github.com/kgaughan/mercury
LABEL org.opencontainers.image.source=https://github.com/kgaughan/mercury
LABEL org.opencontainers.image.documentation=https://kgaughan.github.io/mercury/

RUN apk --no-cache add ca-certificates tzdata
COPY mercury .
USER nobody
ENTRYPOINT ["/mercury"]
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ clean:
rm -rf $(NAME) dist site

$(NAME): $(SOURCE) go.sum
CGO_ENABLED=0 go build -tags netgo -trimpath -ldflags '-s -w' -o $(NAME) ./cmd/$(NAME)
CGO_ENABLED=0 go build -tags netgo,timetzdata -trimpath -ldflags '-s -w' -o $(NAME) ./cmd/$(NAME)

update:
go get -u ./...
Expand Down

0 comments on commit d6e1c2c

Please sign in to comment.