laconicd/Dockerfile
Nabarun 8dd84f23d5
All checks were successful
Unit Tests / test-unit (pull_request) Successful in 56s
Build / build (pull_request) Successful in 52s
SDK Tests / sdk_tests_authority_auctions (pull_request) Successful in 10m12s
Integration Tests / test-integration (pull_request) Successful in 45s
SDK Tests / sdk_tests_nameservice_expiry (pull_request) Successful in 4m38s
SDK Tests / sdk_tests (pull_request) Successful in 14m12s
E2E Tests / test-e2e (pull_request) Successful in 1m47s
Set graphiql package version in GQL playground
2025-05-07 11:15:10 +05:30

35 lines
811 B
Docker

FROM golang:1.21-bullseye AS builder
# Set working directory for the build
WORKDIR /go/src/git.vdb.to/cerc-io/laconicd
# Cache Go modules
COPY go.mod go.sum ./
RUN go mod download
# Add source files
COPY . .
# Make the binary
RUN make build
# Final image
FROM ubuntu:22.04
# Install ca-certificates, jq, curl, bash, and other necessary packages
RUN apt-get update && apt-get install -y --no-install-recommends \
ca-certificates \
jq curl netcat bash bc \
&& rm -rf /var/lib/apt/lists/*
# Copy over binary from the builder
COPY --from=builder /go/src/git.vdb.to/cerc-io/laconicd/build/laconicd /usr/bin/laconicd
# Copy over init script from builder
COPY --from=builder /go/src/git.vdb.to/cerc-io/laconicd/scripts/init.sh scripts/init.sh
WORKDIR /
# Run laconicd by default
CMD ["laconicd"]