generated from KyberNetwork/go-project-template
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathDockerfile-v2
35 lines (24 loc) · 848 Bytes
/
Dockerfile-v2
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
31
32
33
34
35
## BUILDER
FROM golang:1.22-bullseye as builder
WORKDIR /src
COPY . .
RUN go build -o parse_log ./v2/cmd/parse_log
RUN go build -o backfill ./v2/cmd/backfill
RUN go build -o broadcast ./v2/cmd/broadcast
RUN go build -o price_filler ./v2/cmd/price_filler
RUN go build -o tradelogs ./v2/cmd/tradelogs
RUN go build -o promotees ./v2/cmd/promotees
## DEPLOY
FROM debian:bullseye
RUN apt-get update && \
apt install -y ca-certificates && \
rm -rf /var/lib/apt/lists/*
WORKDIR /v2
COPY --from=builder /src/parse_log /v2/parse_log
COPY --from=builder /src/backfill /v2/backfill
COPY --from=builder /src/broadcast /v2/broadcast
COPY --from=builder /src/price_filler /v2/price_filler
COPY --from=builder /src/tradelogs /v2/tradelogs
COPY --from=builder /src/promotees /v2/promotees
COPY v2/cmd/migrations /v2/migrations
CMD /v2/parse_log