mirror of
https://github.com/sablierapp/sablier.git
synced 2025-12-21 13:23:03 +01:00
To access the docker socket you need to be root or in the docker group. The GID changes from one machine to the other. For now the image will be running as root.
24 lines
367 B
Docker
24 lines
367 B
Docker
FROM golang:1.18 AS build
|
|
|
|
ENV PORT 10000
|
|
|
|
WORKDIR /go/src/sablier
|
|
|
|
COPY go.mod ./
|
|
COPY go.sum ./
|
|
RUN go mod download
|
|
|
|
COPY . /go/src/sablier
|
|
|
|
ARG TARGETOS
|
|
ARG TARGETARCH
|
|
RUN make ${TARGETOS}/${TARGETARCH}
|
|
|
|
FROM alpine
|
|
|
|
COPY --from=build /go/src/sablier/sablier* /go/bin/sablier
|
|
|
|
EXPOSE 10000
|
|
|
|
ENTRYPOINT [ "/go/bin/sablier" ]
|
|
CMD [ "start", "--provider.name=docker"] |