From f35efd1e9c61370def7f535120ea77ae982336b7 Mon Sep 17 00:00:00 2001 From: Dan Bond Date: Tue, 15 Jan 2019 15:57:53 +0000 Subject: [PATCH] build: use go 1.11 --- .travis.yml | 4 ++-- Dockerfile | 6 ++++-- configure | 4 ++-- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/.travis.yml b/.travis.yml index 8ef5bcf..f939d99 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,10 +1,10 @@ language: go go: - - 1.9.x - 1.10.x + - 1.11.x install: # Fetch dependencies - - wget -O dep https://github.com/golang/dep/releases/download/v0.3.2/dep-linux-amd64 + - wget -O dep https://github.com/golang/dep/releases/download/v0.5.0/dep-linux-amd64 - chmod +x dep - mv dep $GOPATH/bin/dep script: diff --git a/Dockerfile b/Dockerfile index c141678..c3137f5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,9 +1,11 @@ -FROM golang:1.10 AS builder +FROM golang:1.11-stretch AS builder WORKDIR /go/src/github.com/pusher/oauth2_proxy COPY . . # Fetch dependencies -RUN go get -u github.com/golang/dep/cmd/dep +RUN wget -O dep https://github.com/golang/dep/releases/download/v0.5.0/dep-linux-amd64 +RUN chmod +x dep +RUN mv dep $GOPATH/bin/dep RUN dep ensure --vendor-only # Build image diff --git a/configure b/configure index 7ba3a67..499ae23 100755 --- a/configure +++ b/configure @@ -81,7 +81,7 @@ check_for() { check_go_version() { echo -n "Checking go version... " GO_VERSION=$(${tools[go]} version | ${tools[awk]} '{where = match($0, /[0-9]\.[0-9]+\.[0-9]*/); if (where != 0) print substr($0, RSTART, RLENGTH)}') - vercomp $GO_VERSION 1.9 + vercomp $GO_VERSION 1.10 case $? in 0) ;& 1) @@ -91,7 +91,7 @@ check_go_version() { ;; 2) printf "${RED}" - echo "$GO_VERSION < 1.9" + echo "$GO_VERSION < 1.10" exit 1 ;; esac