2022-04-05 15:30:20 +00:00
|
|
|
FROM golang:alpine AS build-env
|
|
|
|
|
|
|
|
# Install minimum necessary dependencies,
|
|
|
|
ENV PACKAGES curl make git libc-dev bash gcc linux-headers eudev-dev python3
|
|
|
|
RUN apk add --no-cache $PACKAGES
|
|
|
|
|
|
|
|
# Set up dependencies
|
|
|
|
ENV PACKAGES git build-base
|
|
|
|
|
|
|
|
# Set working directory for the build
|
|
|
|
WORKDIR /go/src/github.com/vulcanize/chiba-clonk
|
|
|
|
|
|
|
|
# Add source files
|
|
|
|
COPY . .
|
|
|
|
|
|
|
|
# build binary
|
2022-06-27 05:37:07 +00:00
|
|
|
# RUN make build-linux
|
|
|
|
RUN COSMOS_BUILD_OPTIONS=badgerdb make build
|
2022-04-05 15:30:20 +00:00
|
|
|
|
|
|
|
|
|
|
|
# Final image
|
|
|
|
FROM alpine:edge
|
|
|
|
|
|
|
|
# Install ca-certificates
|
|
|
|
RUN apk add --update ca-certificates jq
|
|
|
|
WORKDIR /
|
|
|
|
|
|
|
|
# Copy over binaries from the build-env
|
|
|
|
COPY --from=build-env /go/src/github.com/vulcanize/chiba-clonk/build/chibaclonkd /usr/bin/chibaclonkd
|
|
|
|
|
|
|
|
EXPOSE 26656 26657 1317 9090 8545 8546
|
|
|
|
|
|
|
|
# Run ethermintd by default
|
2022-06-27 05:37:07 +00:00
|
|
|
CMD ["chibaclonkd","start","--gql-playground","--gql-server","--home","/chibaclonk","--mode","validator","--db-backend","badgerdb"]
|