prometheus-mastodon-exporter/Dockerfile
dependabot[bot] 9d520848a7
Bump alpine from 3.16.3 to 3.17.0 (#3)
Bumps alpine from 3.16.3 to 3.17.0.

---
updated-dependencies:
- dependency-name: alpine
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-25 08:02:43 +00:00

30 lines
688 B
Docker

FROM alpine:3.17.0 as builder
WORKDIR /go/src/github.com/systemli/prometheus-mastodon-exporter
ENV USER=appuser
ENV UID=10001
RUN adduser \
--disabled-password \
--gecos "" \
--home "/nonexistent" \
--shell "/sbin/nologin" \
--no-create-home \
--uid "${UID}" \
"${USER}"
RUN apk add --no-cache --update ca-certificates
FROM scratch
COPY --from=builder /etc/passwd /etc/passwd
COPY --from=builder /etc/group /etc/group
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt
COPY prometheus-mastodon-exporter /prometheus-mastodon-exporter
USER appuser:appuser
EXPOSE 13120
ENTRYPOINT ["/prometheus-mastodon-exporter"]