remove CGO_ENABLED=0 & introduce compose file

This commit is contained in:
m5r 2024-07-20 03:18:49 +02:00
parent b97b2f2131
commit c3220327e1
Signed by: mokhtar
GPG Key ID: 1509B54946D08A95
4 changed files with 22 additions and 5 deletions

View File

@ -1,5 +1,4 @@
ddd ddd
old
loadtest loadtest
.lego.new *.log
.lego.bak local-ip.sh

6
.gitignore vendored
View File

@ -1 +1,5 @@
/.lego /.lego
ddd
loadtest
*.log
local-ip.sh

View File

@ -4,7 +4,7 @@ WORKDIR /app
COPY . . COPY . .
RUN go mod download RUN go mod download
RUN CGO_ENABLED=0 go build -o /app/local-ip RUN go build -o /app/local-ip
FROM gcr.io/distroless/base-debian12:latest FROM gcr.io/distroless/base-debian12:latest

14
compose.yml Normal file
View File

@ -0,0 +1,14 @@
services:
local-ip.sh:
image: local-ip.sh
build: .
volumes:
- lego:/local-ip/.lego
restart: unless-stopped
ports:
- 53:53/udp
- 80:80/tcp
- 443:443/tcp
volumes:
lego: