all repos

onasty @ e075c324c446934958b3a537a3dfdb14c404fb7c

a one-time notes service

onasty/Dockerfile(view raw)

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
FROM golang:1.23.2-alpine AS builder

WORKDIR /app

COPY go.mod go.sum ./
RUN go mod download

COPY cmd cmd
COPY internal internal

RUN CGO_ENABLED=0 GOOS=linux go build -ldflags='-w -s' -o /onasty ./cmd/server

FROM alpine:3.20
COPY --from=builder /onasty /onasty
RUN apk --no-cache add ca-certificates
ENTRYPOINT ["/onasty"]