cic-custodial/Dockerfile

24 lines
501 B
Docker
Raw Normal View History

2023-02-24 17:48:23 +01:00
FROM golang:1.20-bullseye as build
WORKDIR /build
COPY . .
2023-02-20 11:26:21 +01:00
RUN CGO_ENABLED=1 GOOS=linux GOARCH=amd64 go build -o cic-custodial -ldflags="-s -w" cmd/service/*.go
FROM debian:bullseye-slim
2022-11-30 10:51:24 +01:00
2022-12-01 09:09:46 +01:00
ENV DEBIAN_FRONTEND=noninteractive
RUN set -x && \
apt-get update && \
apt-get install -y ca-certificates && \
rm -rf /var/cache/apt/archives /var/lib/apt/lists/*
2022-11-30 10:51:24 +01:00
2022-12-01 09:09:46 +01:00
WORKDIR /service
2022-11-30 10:51:24 +01:00
COPY --from=build /build/cic-custodial .
2022-11-30 10:51:24 +01:00
COPY config.toml .
2023-02-28 11:37:30 +01:00
COPY queries.sql .
2022-11-30 10:51:24 +01:00
2022-12-01 09:09:46 +01:00
CMD ["./cic-custodial"]
2022-11-30 10:51:24 +01:00
EXPOSE 5000