Skip to content

Commit

Permalink
update to 1.16, minimize docker image size, go mod tidy
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergey Kibish committed May 2, 2021
1 parent be164ff commit 29fca9c
Show file tree
Hide file tree
Showing 11 changed files with 19 additions and 2,118 deletions.
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# To run: docker run -v /path/to/config.yml:/config/.ddns.yml ddns -conf-file /config/.ddns.yml
# Or if your .ddns.yml is in the current working directory and is named .ddns.yml
# docker run -v ${PWD}:/config ddns
FROM golang:1.13.1-alpine as builder
FROM golang:1.16.3-alpine as builder

WORKDIR /app

Expand All @@ -12,10 +12,10 @@ RUN go mod download && go mod verify

# Copy everything in and do the go build
COPY . .
RUN go build -v
RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o ddns .

# Now create a new stage and only copy the binary we need (keeps the container small)
FROM alpine:3.10.2
FROM scratch
COPY --from=builder /app/ddns /

ENTRYPOINT ["/ddns"]
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@ require (
gopkg.in/yaml.v2 v2.0.0-20170208141851-a3f3340b5840
)

go 1.13
go 1.16
62 changes: 0 additions & 62 deletions vendor/golang.org/x/sys/unix/mkpost.go

This file was deleted.

250 changes: 0 additions & 250 deletions vendor/golang.org/x/sys/unix/types_darwin.go

This file was deleted.

Loading

0 comments on commit 29fca9c

Please sign in to comment.