2022-06-29 00:41:56 +05:00
|
|
|
FROM code.pztrn.name/containers/mirror/golang:1.18.3-alpine AS build
|
2020-12-23 20:07:14 +05:00
|
|
|
|
|
|
|
WORKDIR /go/src/gitlab.pztrn.name/pztrn/metricator
|
|
|
|
COPY . .
|
|
|
|
|
|
|
|
ARG CI_PROJECT_NAME
|
|
|
|
ARG CI_COMMIT_SHA
|
|
|
|
ARG CI_COMMIT_REF_NAME
|
|
|
|
ARG CI_COMMIT_TAG
|
|
|
|
|
|
|
|
ENV CGO_ENABLED=0
|
2020-12-23 20:18:18 +05:00
|
|
|
RUN apk add bash git make
|
2020-12-23 20:07:14 +05:00
|
|
|
RUN make metricatord-build
|
2020-12-24 23:17:38 +05:00
|
|
|
RUN make metricator-client-build
|
2020-12-23 20:07:14 +05:00
|
|
|
|
2022-06-29 00:41:56 +05:00
|
|
|
FROM code.pztrn.name/containers/mirror/golang:1.18.3-alpine
|
2020-12-23 20:07:14 +05:00
|
|
|
LABEL maintainer="Stanislav N. <pztrn@pztrn.name>"
|
|
|
|
|
2020-12-23 20:28:24 +05:00
|
|
|
COPY --from=build /go/src/gitlab.pztrn.name/pztrn/metricator/._bin/metricatord /usr/local/bin/metricatord
|
2020-12-24 23:17:38 +05:00
|
|
|
COPY --from=build /go/src/gitlab.pztrn.name/pztrn/metricator/._bin/metricator-client /usr/local/bin/metricator-client
|
2020-12-23 20:07:14 +05:00
|
|
|
|
|
|
|
RUN apk add tzdata
|
|
|
|
|
|
|
|
ENTRYPOINT [ "/usr/local/bin/metricatord", "-config", "/config.yaml" ]
|