-
Notifications
You must be signed in to change notification settings - Fork 32
/
Dockerfile
56 lines (39 loc) · 1.21 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
49
50
51
52
53
54
55
FROM golang:1.18 AS build
RUN apt-get update -y && \
apt-get install -y rsync
WORKDIR /app/
COPY . ./
WORKDIR /app/avalanchego/
RUN /app/avalanchego/scripts/build.sh
FROM ubuntu@sha256:b25ef49a40b7797937d0d23eca3b0a41701af6757afca23d504d50826f0b37ce
WORKDIR /app
ENV HTTP_HOST=0.0.0.0 \
HTTP_PORT=9650 \
STAKING_PORT=9651 \
PUBLIC_IP= \
DB_DIR=/app/db \
DB_TYPE=leveldb \
BOOTSTRAP_IPS= \
BOOTSTRAP_IDS= \
CHAIN_CONFIG_DIR=/app/conf \
LOG_DIR=/app/logs \
LOG_LEVEL=info \
NETWORK_ID=coston \
AUTOCONFIGURE_PUBLIC_IP=1 \
AUTOCONFIGURE_BOOTSTRAP=1 \
AUTOCONFIGURE_BOOTSTRAP_ENDPOINT=https://coston.flare.network/ext/info \
EXTRA_ARGUMENTS="" \
BOOTSTRAP_BEACON_CONNECTION_TIMEOUT="1m"
RUN apt-get update -y && \
apt-get install -y curl jq
RUN mkdir -p /app/conf/coston /app/conf/C /app/logs /app/db
COPY --from=build /app/avalanchego/build /app/build
COPY entrypoint.sh /app/entrypoint.sh
EXPOSE ${STAKING_PORT}
EXPOSE ${HTTP_PORT}
VOLUME [ "${DB_DIR}" ]
VOLUME [ "${LOG_DIR}" ]
VOLUME [ "${CHAIN_CONFIG_DIR}" ]
HEALTHCHECK CMD curl --fail http://localhost:${HTTP_PORT}/ext/health || exit 1
ENTRYPOINT [ "/usr/bin/bash" ]
CMD [ "/app/entrypoint.sh" ]