Files
docker-dnscache/Dockerfile
paspo 19efc7c213
All checks were successful
Container Publish / on-success-skip (push) Has been skipped
Container Publish / build-image (arm64) (push) Successful in 1m7s
Container Publish / build-image (amd64) (push) Successful in 1m22s
Container Publish / update docker manifest (push) Successful in 10s
go upgrade
2025-09-29 20:14:01 +02:00

24 lines
575 B
Docker

FROM golang:1.25.1-alpine AS build
WORKDIR /src
COPY src /src
RUN \
go mod download && \
CGO_ENABLED=0 GOOS=linux go build -a -o /dnsproxy cmd/main.go
FROM alpine:latest
RUN \
apk --no-cache upgrade && \
apk --no-cache add unbound bind-tools tini && \
wget -O /etc/unbound/named.cache ftp://ftp.internic.net//domain/named.cache
COPY rootfs /
COPY --from=build /dnsproxy /app/
HEALTHCHECK --interval=30s --start-period=5s --timeout=10s \
CMD /usr/bin/host -T -p ${PORT} asperti.com 127.0.0.1
ENTRYPOINT ["/sbin/tini", "--", "/bin/sh", "/app/entrypoint.sh"]