2024-07-25 18:48:25 +02:00
|
|
|
FROM golang:alpine AS builder
|
|
|
|
|
|
|
|
WORKDIR /app
|
|
|
|
COPY . .
|
2024-08-06 11:42:37 +02:00
|
|
|
RUN apt install tar/stable
|
2024-07-25 18:48:25 +02:00
|
|
|
RUN go build .
|
|
|
|
RUN mkdir workflows/
|
|
|
|
|
|
|
|
FROM scratch
|
|
|
|
|
|
|
|
WORKDIR /app
|
|
|
|
|
2024-08-06 11:42:37 +02:00
|
|
|
COPY --from=builder /bin/tar /bin/tar
|
2024-07-25 18:48:25 +02:00
|
|
|
COPY conf/ocmonitor_conf.json /app/conf/
|
|
|
|
COPY --from=builder /app/oc-monitor .
|
|
|
|
COPY --from=builder /app/workflows/ .
|
|
|
|
|
|
|
|
ENTRYPOINT [ "/app/oc-monitor" ]
|