From fec2879ec07a88278af6c54ff590aac2950bf417 Mon Sep 17 00:00:00 2001 From: Wayback Archiver <66856220+waybackarchiver@users.noreply.github.com> Date: Tue, 9 May 2023 05:21:00 +0000 Subject: [PATCH] Use build directive from makefile --- Dockerfile | 2 +- Makefile | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index cfe3f48..42ce2d4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,7 +4,7 @@ FROM golang:1.18 as build WORKDIR /usr/src/wireproxy COPY . . -RUN CGO_ENABLED=0 go build ./cmd/wireproxy +RUN make # Now copy it into our base image. FROM gcr.io/distroless/static-debian11:nonroot diff --git a/Makefile b/Makefile index 57004f1..7b65151 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,5 @@ export GO ?= go +export CGO_ENABLED = 0 TAG := $(shell git describe --always --tags $(git rev-list --tags --max-count=1) --match v*)