From b092f8bc99b3481241c14bbaee813eeefa6c1eab Mon Sep 17 00:00:00 2001 From: rimas Date: Thu, 17 Jun 2021 10:03:29 +0300 Subject: [PATCH] Remove gocenter.io proxy, use go 1.15 --- Dockerfile | 5 ++--- Makefile | 9 ++++----- go.mod | 2 +- 3 files changed, 7 insertions(+), 9 deletions(-) diff --git a/Dockerfile b/Dockerfile index 174c591..7cf3f2f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,4 @@ -FROM golang:1.13-alpine AS builder -MAINTAINER "" +FROM golang:1.15-alpine AS builder ARG srcpath="/build/hostpath-provisioner" @@ -9,7 +8,7 @@ RUN apk --no-cache add git && \ ADD . "$srcpath" RUN cd "$srcpath" && \ - GO111MODULE=on GOPROXY=https://gocenter.io \ + GO111MODULE=on \ CGO_ENABLED=0 GOOS=linux GOARCH=amd64 \ go build -a -ldflags '-extldflags "-static"' -o /hostpath-provisioner diff --git a/Makefile b/Makefile index 9fdfaa9..deca662 100644 --- a/Makefile +++ b/Makefile @@ -1,16 +1,16 @@ # IMAGE?=quay.io/rimusz/hostpath-provisioner -TAG_GIT=$(IMAGE):v0.2.3 +TAG_GIT=$(IMAGE):v0.2.4 TAG_LATEST=$(IMAGE):latest -PHONY: all -all: image push - PHONY: test-image test-image: docker build -t hostpath-provisioner -f Dockerfile . +PHONY: all +all: image push + PHONY: image image: docker build -t $(TAG_GIT) -f Dockerfile . @@ -24,6 +24,5 @@ push: PHONY: hostpath-provisioner hostpath-provisioner: export CGO_ENABLED=0 hostpath-provisioner: export GO111MODULE=on -hostpath-provisioner: export GOPROXY=https://gocenter.io hostpath-provisioner: $(shell find . -name "*.go") go build -a -ldflags '-extldflags "-static"' -o hostpath-provisioner . diff --git a/go.mod b/go.mod index d86cdf5..60506d8 100644 --- a/go.mod +++ b/go.mod @@ -41,4 +41,4 @@ require ( sigs.k8s.io/yaml v1.1.0 // indirect ) -go 1.13 +go 1.15