2022-01-06 10:07:57 +00:00
|
|
|
FROM golang:1 as gobuild
|
2020-09-02 15:23:40 +00:00
|
|
|
|
|
|
|
RUN apt-get update && \
|
2024-05-31 12:02:20 +00:00
|
|
|
apt-get install -y build-essential git
|
2020-09-02 15:23:40 +00:00
|
|
|
|
|
|
|
WORKDIR /go/src/git.nemunai.re/chldapasswd
|
|
|
|
|
|
|
|
ADD . .
|
|
|
|
|
2024-05-31 12:02:20 +00:00
|
|
|
RUN go get -d && \
|
|
|
|
go build -ldflags="-s -w"
|
2020-09-02 15:23:40 +00:00
|
|
|
|
|
|
|
|
|
|
|
FROM debian:stable-slim
|
|
|
|
|
|
|
|
RUN apt-get update && \
|
|
|
|
apt-get install -y ca-certificates && \
|
|
|
|
rm -rf /var/lib/apt/lists/*
|
|
|
|
|
|
|
|
EXPOSE 8080
|
|
|
|
|
2022-01-06 10:07:57 +00:00
|
|
|
USER nobody
|
|
|
|
|
2020-09-02 15:23:40 +00:00
|
|
|
WORKDIR /srv
|
|
|
|
|
|
|
|
ENTRYPOINT ["/srv/chldapasswd", "-bind=:8080"]
|
|
|
|
|
|
|
|
COPY --from=gobuild /go/src/git.nemunai.re/chldapasswd/chldapasswd /srv/chldapasswd
|