mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
* devenv: update prom random_data for go1.17 (use go install) * restore env vars and tags to install cmd
14 lines
504 B
Docker
14 lines
504 B
Docker
# This Dockerfile builds an image for a client_golang example.
|
|
|
|
# Builder image, where we build the example.
|
|
FROM golang:1.17 AS builder
|
|
# Download prometheus/client_golang/examples/random first
|
|
RUN CGO_ENABLED=0 GOOS=linux go install -tags netgo -ldflags '-w' github.com/prometheus/client_golang/examples/random@latest
|
|
|
|
# Final image.
|
|
FROM scratch
|
|
LABEL maintainer "The Prometheus Authors <prometheus-developers@googlegroups.com>"
|
|
COPY --from=builder /go/bin/random .
|
|
EXPOSE 8080
|
|
ENTRYPOINT ["/random"]
|