-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
48 lines (38 loc) · 1.65 KB
/
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
FROM rustlang/rust:nightly AS builder
RUN apt update && apt install -y protobuf-compiler
COPY backend backend
COPY Cargo.toml /
COPY Cargo.lock /
RUN cargo build --release
FROM debian:bullseye-slim as runner
RUN apt update -y && apt install -y libpq-dev libssl-dev ca-certificates
RUN update-ca-certificates
ENV SSL_CERT_FILE=/etc/ssl/certs/ca-certificates.crt
FROM runner as graphql
COPY --from=builder ./target/release/csb-graphql-api ./app/csb-graphql-api
CMD ["/app/csb-graphql-api"]
FROM runner as chainlink-collector
COPY --from=builder ./target/release/chainlink-collector ./app/chainlink-collector
CMD ["/app/chainlink-collector"]
FROM runner as coingecko-collector
COPY --from=builder ./target/release/coingecko-collector ./app/coingecko-collector
CMD ["/app/coingecko-collector"]
FROM runner as cryptocompare-collector
COPY --from=builder ./target/release/cryptocompare-collector ./app/cryptocompare-collector
CMD ["/app/cryptocompare-collector"]
FROM runner as gateio-collector
COPY --from=builder ./target/release/gateio-collector ./app/gateio-collector
CMD ["/app/gateio-collector"]
FROM runner as aggregator
COPY --from=builder ./target/release/price-aggregator ./app/price-aggregator
CMD ["/app/price-aggregator"]
FROM runner as user-service
COPY --from=builder ./target/release/user-service ./app/user-service
CMD ["/app/user-service"]
FROM runner as notification-service
COPY --from=builder ./target/release/notification-service ./app/notification-service
CMD ["/app/notification-service"]
FROM runner as telegram-notification
RUN apt update --yes && apt install openssl --yes
COPY --from=builder ./target/release/tg-service ./app/tg-service
CMD ["/app/tg-service"]