mirror of
https://github.com/prymitive/karma
synced 2026-05-05 03:16:51 +00:00
24 lines
890 B
Docker
24 lines
890 B
Docker
FROM node:10.14.2-alpine as nodejs-builder
|
|
RUN apk add --update make git
|
|
COPY . /karma
|
|
RUN make -C /karma ui
|
|
|
|
FROM golang:1.11.4-alpine as go-builder
|
|
COPY --from=nodejs-builder /karma /go/src/github.com/prymitive/karma
|
|
ARG VERSION
|
|
RUN apk add --update make git
|
|
RUN CGO_ENABLED=0 make -C /go/src/github.com/prymitive/karma VERSION="${VERSION:-dev}" karma
|
|
|
|
FROM alpine:latest
|
|
RUN apk add --update supervisor python && rm -rf /tmp/* /var/cache/apk/*
|
|
COPY demo/supervisord.conf /etc/supervisord.conf
|
|
COPY --from=prom/alertmanager:latest /bin/alertmanager /alertmanager
|
|
COPY demo/alertmanager.yaml /etc/alertmanager.yaml
|
|
COPY demo/generator.py /generator.py
|
|
COPY --from=go-builder /go/src/github.com/prymitive/karma/karma /karma
|
|
COPY demo/karma.yaml /etc/karma.yaml
|
|
COPY demo/custom.js /custom.js
|
|
RUN adduser -D karma
|
|
USER karma
|
|
CMD supervisord --nodaemon --configuration /etc/supervisord.conf
|