mirror of
https://github.com/wahyd4/golink.git
synced 2026-08-09 05:05:56 +10:00
Even though we have our own build and deploy scripts, most users will be more comfortable with a standard Dockerfile. We could publish our scripts later if warranted. For now, we'll just keep them in corp.
19 lines
333 B
Docker
19 lines
333 B
Docker
FROM cgr.dev/chainguard/go:1.19 as build
|
|
|
|
WORKDIR /work
|
|
|
|
COPY go.mod go.sum ./
|
|
RUN go mod download
|
|
|
|
COPY . .
|
|
RUN CGO_ENABLED=0 GOOS=linux go build -v ./cmd/golink
|
|
|
|
|
|
FROM cgr.dev/chainguard/static:latest
|
|
|
|
ENV HOME /root
|
|
|
|
COPY --from=build /work/golink /golink
|
|
ENTRYPOINT ["/golink"]
|
|
CMD ["--sqlitedb", "/root/golink.db", "--verbose"]
|