forked from oren-lava/cli
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
51 lines (37 loc) · 885 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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
# syntax = docker/dockerfile:1.2
# WARNING! Use `DOCKER_BUILDKIT=1` with `docker build` to enable --mount feature.
## prep the base image.
#
FROM golang as base
RUN apt update && \
apt-get install -y \
build-essential \
ca-certificates \
curl
# enable faster module downloading.
ENV GOPROXY https://proxy.golang.org
## builder stage.
#
FROM base as builder
WORKDIR /ignite
# cache dependencies.
COPY ./go.mod .
COPY ./go.sum .
RUN go mod download
COPY . .
RUN --mount=type=cache,target=/root/.cache/go-build go install -v ./...
## prep the final image.
#
FROM base
RUN useradd -ms /bin/bash tendermint
USER tendermint
COPY --from=builder /go/bin/ignite /usr/bin
WORKDIR /apps
# see docs for exposed ports:
# https://docs.ignite.com/kb/config.html#host
EXPOSE 26657
EXPOSE 26656
EXPOSE 6060
EXPOSE 9090
EXPOSE 1317
ENTRYPOINT ["ignite"]