forked from migalabs/armiarma
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
30 lines (22 loc) · 767 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# syntax=docker/dockerfile:1
# chosen buster image for
FROM golang:1.17.3-buster AS builder
COPY ./ /armiarma
WORKDIR /armiarma
RUN go get
RUN go build -o ./armiarma-client
# FINAL STAGE -> copy the binary and few config files
FROM debian:buster-slim
RUN mkdir /armiarma
# Generate the peerstore folder where the peerstore and the metrics will be stored
RUN mkdir /armiarma/peerstore
RUN mkdir /armiarma/config-file
COPY --from=builder /armiarma/src /armiarma/src
COPY --from=builder /armiarma/armiarma-client /armiarma/armiarma-client
WORKDIR /armiarma
# Crawler exposed Port
EXPOSE 9020
# Crawler exposed Port for Prometheus data export
EXPOSE 9080
# Arguments coming from the docker call: (1)->armiarma-client (2)->flags
ENTRYPOINT ["./armiarma-client"]