Files
2026-10-30 10:56:13 +01:00

12 lines
455 B
Docker

FROM golang:1.23-alpine AS build
WORKDIR /src
COPY . .
RUN CGO_ENABLED=0 go test ./... && CGO_ENABLED=0 go build -trimpath -ldflags="-s -w -buildid=" -o /out/ts3monolith ./cmd/ts3monolith
FROM alpine:3.20
RUN apk add --no-cache ca-certificates tzdata rrdtool && addgroup -g 10001 app && adduser -D -H -u 10001 -G app app
COPY --from=build /out/ts3monolith /usr/local/bin/ts3monolith
USER 10001:10001
EXPOSE 8080
ENTRYPOINT ["/usr/local/bin/ts3monolith"]