Skip to content

Commit

Permalink
remove dockerfile arg defaults
Browse files Browse the repository at this point in the history
  • Loading branch information
jaredLunde committed Dec 29, 2024
1 parent 755bb17 commit 498031a
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ RUN go mod download && go mod tidy

FROM deps AS vips-builder
ARG VIPS_VERSION=8.16.0
ARG TARGETOS
ARG TARGETARCH
ENV PKG_CONFIG_PATH=/usr/local/lib/pkgconfig

RUN DEBIAN_FRONTEND=noninteractive \
Expand Down Expand Up @@ -50,11 +52,10 @@ RUN cd /tmp && \

FROM vips-builder AS build
WORKDIR /go/src/app
ARG TARGETOS=linux
ARG TARGETARCH=amd64

ARG TARGETOS
ARG TARGETARCH
COPY . .
RUN GOOS=${TARGETOS} GOARCH=${TARGETARCH} go build -trimpath -ldflags="-s -w" -o /go/bin/app ./cmd/server
RUN GOOS=${TARGETOS} GOARCH=${TARGETARCH} CGO_ENABLED=1 go build -trimpath -ldflags="-s -w" -o /go/bin/app ./cmd/server

FROM debian:stable-slim
WORKDIR /app
Expand Down

0 comments on commit 498031a

Please sign in to comment.