From d3dfbf08e8df415734aeddeccce9f83c27c7aae3 Mon Sep 17 00:00:00 2001 From: Denis Gukov Date: Tue, 21 Jun 2022 18:36:59 +0500 Subject: [PATCH] feat(be): update for go 1.18 --- .github/workflows/dev.yml | 25 ++++++++++++------------- .github/workflows/release.yml | 8 ++++---- deployment/docker/ci/Dockerfile | 2 +- deployment/docker/ci/dredd.Dockerfile | 2 +- deployment/docker/dev/Dockerfile | 2 +- deployment/docker/dev/dredd.Dockerfile | 2 +- deployment/docker/prod/Dockerfile | 2 +- go.mod | 21 +++++++++++++++------ 8 files changed, 36 insertions(+), 28 deletions(-) diff --git a/.github/workflows/dev.yml b/.github/workflows/dev.yml index b031081d..666c1a70 100644 --- a/.github/workflows/dev.yml +++ b/.github/workflows/dev.yml @@ -3,19 +3,18 @@ on: push: branches: - develop - - github_actions jobs: build-local: runs-on: [ubuntu-latest] steps: - uses: actions/setup-go@v3 - with: { go-version: 1.17 } + with: { go-version: 1.18 } - uses: actions/setup-node@v3 with: { node-version: '16' } - - run: go get github.com/go-task/task/v3/cmd/task + - run: go install github.com/go-task/task/v3/cmd/task@latest - uses: actions/checkout@v3 @@ -38,12 +37,12 @@ jobs: # runs-on: [ubuntu-latest] # steps: # - uses: actions/setup-go@v3 - # with: { go-version: 1.17 } + # with: { go-version: 1.18 } # - uses: actions/setup-node@v3 # with: { node-version: '14' } - # - run: go get github.com/go-task/task/v3/cmd/task + # - run: go install github.com/go-task/task/v3/cmd/task@latest # - uses: actions/checkout@v3 @@ -65,9 +64,9 @@ jobs: needs: build-local steps: - uses: actions/setup-go@v3 - with: { go-version: 1.17 } + with: { go-version: 1.18 } - - run: go get github.com/go-task/task/v3/cmd/task + - run: go install github.com/go-task/task/v3/cmd/task@latest - uses: actions/checkout@v3 @@ -102,9 +101,9 @@ jobs: needs: [test-db-migration] steps: - uses: actions/setup-go@v3 - with: { go-version: 1.17 } + with: { go-version: 1.18 } - - run: go get github.com/go-task/task/v3/cmd/task + - run: go install github.com/go-task/task/v3/cmd/task@latest - uses: actions/checkout@v3 @@ -116,9 +115,9 @@ jobs: # runs-on: [ubuntu-latest] # steps: # - uses: actions/setup-go@v3 - # with: { go-version: 1.17 } + # with: { go-version: 1.18 } - # - run: go get github.com/go-task/task/v3/cmd/task + # - run: go install github.com/go-task/task/v3/cmd/task@latest # - uses: actions/checkout@v3 @@ -130,9 +129,9 @@ jobs: # runs-on: [ubuntu-latest] # steps: # - uses: actions/setup-go@v3 - # with: { go-version: 1.17 } + # with: { go-version: 1.18 } - # - run: go get github.com/go-task/task/v3/cmd/task + # - run: go install github.com/go-task/task/v3/cmd/task@latest # - uses: actions/checkout@v3 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 696800be..b791781e 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -9,9 +9,9 @@ jobs: # runs-on: [ubuntu-latest] # steps: # - uses: actions/setup-go@v3 - # with: { go-version: 1.17 } + # with: { go-version: 1.18 } - # - run: go get github.com/go-task/task/v3/cmd/task + # - run: go install github.com/go-task/task/v3/cmd/task@latest # - uses: actions/checkout@v3 @@ -28,12 +28,12 @@ jobs: runs-on: [ubuntu-latest] steps: - uses: actions/setup-go@v3 - with: { go-version: 1.17 } + with: { go-version: 1.18 } - uses: actions/setup-node@v3 with: { node-version: '16' } - - run: go get github.com/go-task/task/v3/cmd/task + - run: go install github.com/go-task/task/v3/cmd/task@latest - run: sudo apt update && sudo apt-get install rpm diff --git a/deployment/docker/ci/Dockerfile b/deployment/docker/ci/Dockerfile index 299dbbb5..78e443c7 100644 --- a/deployment/docker/ci/Dockerfile +++ b/deployment/docker/ci/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.16.3-alpine3.13 +FROM golang:1.18.3-alpine3.16 ENV SEMAPHORE_VERSION="development" SEMAPHORE_ARCH="linux_amd64" \ SEMAPHORE_CONFIG_PATH="${SEMAPHORE_CONFIG_PATH:-/etc/semaphore}" \ diff --git a/deployment/docker/ci/dredd.Dockerfile b/deployment/docker/ci/dredd.Dockerfile index aa789e25..4242bb3d 100644 --- a/deployment/docker/ci/dredd.Dockerfile +++ b/deployment/docker/ci/dredd.Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.16.3-alpine3.13 as golang +FROM golang:1.18.3-alpine3.16 as golang RUN apk add --no-cache curl git diff --git a/deployment/docker/dev/Dockerfile b/deployment/docker/dev/Dockerfile index 07f29ba6..fc2dbeb2 100644 --- a/deployment/docker/dev/Dockerfile +++ b/deployment/docker/dev/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.16.3-alpine3.13 +FROM golang:1.18.3-alpine3.16 ENV SEMAPHORE_VERSION="development" SEMAPHORE_ARCH="linux_amd64" \ SEMAPHORE_CONFIG_PATH="${SEMAPHORE_CONFIG_PATH:-/etc/semaphore}" \ diff --git a/deployment/docker/dev/dredd.Dockerfile b/deployment/docker/dev/dredd.Dockerfile index 6bd4ae51..9a81d59f 100644 --- a/deployment/docker/dev/dredd.Dockerfile +++ b/deployment/docker/dev/dredd.Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.16.3-alpine3.13 as golang +FROM golang:1.18.3-alpine3.16 as golang RUN apk add --no-cache curl git diff --git a/deployment/docker/prod/Dockerfile b/deployment/docker/prod/Dockerfile index 7c7adf80..a7940675 100644 --- a/deployment/docker/prod/Dockerfile +++ b/deployment/docker/prod/Dockerfile @@ -1,5 +1,5 @@ # ansible-semaphore production image -FROM golang:1.16.3-alpine3.13 as builder +FROM golang:1.18.3-alpine3.16 as builder LABEL maintainer="Tom Whiston " diff --git a/go.mod b/go.mod index 1ab0756c..9da33b6b 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/ansible-semaphore/semaphore -go 1.16 +go 1.18 require ( github.com/Sirupsen/logrus v1.0.4 @@ -9,23 +9,32 @@ require ( github.com/go-sql-driver/mysql v1.4.1 github.com/gobuffalo/packr v1.10.4 github.com/google/go-github v17.0.0+incompatible - github.com/google/go-querystring v1.1.0 // indirect github.com/gorilla/context v0.0.0-20160226214623-1ea25387ff6f github.com/gorilla/handlers v1.4.2 github.com/gorilla/mux v1.7.3 github.com/gorilla/securecookie v1.1.1 github.com/gorilla/websocket v1.4.1 - github.com/lann/builder v0.0.0-20180216234317-1b87b36280d0 // indirect - github.com/lann/ps v0.0.0-20150810152359-62de8c46ede0 // indirect github.com/lib/pq v1.2.0 github.com/masterminds/squirrel v0.0.0-20170825200431-a6b93000bd21 - github.com/pkg/errors v0.9.1 // indirect github.com/robfig/cron/v3 v3.0.1 - github.com/sirupsen/logrus v1.4.2 // indirect github.com/snikch/goodman v0.0.0-20171125024755-10e37e294daa github.com/spf13/cobra v1.2.1 go.etcd.io/bbolt v1.3.2 golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9 +) + +require ( + github.com/Azure/go-ntlmssp v0.0.0-20200615164410-66371956d46c // indirect + github.com/go-asn1-ber/asn1-ber v1.5.1 // indirect + github.com/google/go-querystring v1.1.0 // indirect + github.com/inconshreveable/mousetrap v1.0.0 // indirect + github.com/lann/builder v0.0.0-20180216234317-1b87b36280d0 // indirect + github.com/lann/ps v0.0.0-20150810152359-62de8c46ede0 // indirect + github.com/pkg/errors v0.9.1 // indirect + github.com/sirupsen/logrus v1.4.2 // indirect + github.com/spf13/pflag v1.0.5 // indirect + golang.org/x/sys v0.0.0-20210510120138-977fb7262007 // indirect + google.golang.org/appengine v1.6.7 // indirect gopkg.in/airbrake/gobrake.v2 v2.0.9 // indirect gopkg.in/gemnasium/logrus-airbrake-hook.v2 v2.1.2 // indirect )