Skip to content

Commit a8082ec

Browse files
authored
Merge pull request #354 from Kuadrant/go-1-18
Upgrade to Golang v1.18.x
2 parents 02b08a2 + 606d2bc commit a8082ec

File tree

9 files changed

+26
-25
lines changed

9 files changed

+26
-25
lines changed

.github/workflows/code-style.yaml

+7-7
Original file line numberDiff line numberDiff line change
@@ -37,13 +37,13 @@ jobs:
3737
- tool: gofmt
3838
options: -s
3939
- tool: goimports
40-
importpath: golang.org/x/tools/cmd/goimports
40+
importpath: golang.org/x/tools/cmd/goimports@latest
4141

4242
steps:
43-
- name: Set up Go 1.17.x
43+
- name: Set up Go 1.18.x
4444
uses: actions/setup-go@v2
4545
with:
46-
go-version: 1.17.x
46+
go-version: 1.18.x
4747
id: go
4848

4949
- name: Check out code
@@ -53,7 +53,7 @@ jobs:
5353
if: ${{ matrix.importpath != '' }}
5454
run: |
5555
cd $(mktemp -d)
56-
GO111MODULE=on go get ${{ matrix.importpath }}
56+
GO111MODULE=on go install ${{ matrix.importpath }}
5757
5858
- name: ${{ matrix.tool }} ${{ matrix.options }}
5959
shell: bash
@@ -88,10 +88,10 @@ jobs:
8888
runs-on: ubuntu-latest
8989

9090
steps:
91-
- name: Set up Go 1.17.x
91+
- name: Set up Go 1.18.x
9292
uses: actions/setup-go@v2
9393
with:
94-
go-version: 1.17.x
94+
go-version: 1.18.x
9595
id: go
9696

9797
- name: Check out code
@@ -109,7 +109,7 @@ jobs:
109109
echo '::endgroup::'
110110
111111
echo '::group:: Installing misspell ... https://github.com/client9/misspell'
112-
go get github.com/client9/misspell/cmd/misspell
112+
go install github.com/client9/misspell/cmd/misspell@latest
113113
echo '::endgroup::'
114114
115115
echo '::group:: Installing woke ... https://github.com/get-woke/woke'

.github/workflows/e2e-test.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
name: End-to-end Tests
1414
strategy:
1515
matrix:
16-
go-version: [1.17.x]
16+
go-version: [1.18.x]
1717
platform: [ubuntu-latest]
1818
runs-on: ${{ matrix.platform }}
1919
defaults:

.github/workflows/go-test.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
name: Unit Tests
1313
strategy:
1414
matrix:
15-
go-version: [1.17.x]
15+
go-version: [1.18.x]
1616
platform: [ubuntu-latest]
1717
runs-on: ${{ matrix.platform }}
1818
defaults:

.github/workflows/integration-test.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
name: Smoke Tests
1313
strategy:
1414
matrix:
15-
go-version: [1.17.x]
15+
go-version: [1.18.x]
1616
platform: [ubuntu-latest]
1717
runs-on: ${{ matrix.platform }}
1818
if: ${{ github.event.workflow_run.conclusion == 'success' }}

Dockerfile

+12-3
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,23 @@
11
# Build the authorino binary
2-
FROM registry.access.redhat.com/ubi8/go-toolset:1.17.10 as builder
2+
FROM registry.access.redhat.com/ubi9-minimal:latest AS builder
33
USER root
4+
RUN microdnf install -y tar gzip
5+
RUN arch=""; \
6+
case $(uname -m) in \
7+
x86_64) arch="amd64";; \
8+
aarch64) arch="arm64";; \
9+
esac; \
10+
curl -O -J "https://dl.google.com/go/go1.18.7.linux-${arch}.tar.gz"; \
11+
tar -C /usr/local -xzf go1.18.7.linux-${arch}.tar.gz; \
12+
ln -s /usr/local/go/bin/go /usr/local/bin/go
413
WORKDIR /workspace
514
COPY ./ ./
615
ARG version=latest
716
RUN CGO_ENABLED=0 GO111MODULE=on go build -a -ldflags "-X main.version=${version}" -o authorino main.go
817

918
# Use Red Hat minimal base image to package the binary
10-
# https://catalog.redhat.com/software/containers/ubi8-minimal
11-
FROM registry.access.redhat.com/ubi8/ubi-minimal:latest
19+
# https://catalog.redhat.com/software/containers/ubi9-minimal
20+
FROM registry.access.redhat.com/ubi9-minimal:latest
1221
WORKDIR /
1322
COPY --from=builder /workspace/authorino .
1423
USER 1001

docs/contributing.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
## Technology stack for developers
2020

2121
Minimum requirements to contribute to Authorino are:
22-
- [Golang v1.17+](https://golang.org)
22+
- [Golang v1.18+](https://golang.org)
2323
- [Docker](https://docker.com)
2424

2525
Authorino's code was originally bundled using the [Operator SDK](https://sdk.operatorframework.io/) (v1.9.0).

docs/user-guides/metrics.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -416,7 +416,7 @@ go_gc_pauses_seconds_total_count 26
416416
go_goroutines 80
417417
# HELP go_info Information about the Go environment.
418418
# TYPE go_info gauge
419-
go_info{version="go1.17.7"} 1
419+
go_info{version="go1.18.7"} 1
420420
# HELP go_memory_classes_heap_free_bytes Memory that is completely free and eligible to be returned to the underlying system, but has not been. This metric is the runtime's estimate of free address space that is backed by physical memory.
421421
# TYPE go_memory_classes_heap_free_bytes gauge
422422
go_memory_classes_heap_free_bytes 589824
@@ -815,7 +815,7 @@ go_gc_pauses_seconds_total_count 22
815815
go_goroutines 79
816816
# HELP go_info Information about the Go environment.
817817
# TYPE go_info gauge
818-
go_info{version="go1.17.7"} 1
818+
go_info{version="go1.18.7"} 1
819819
# HELP go_memory_classes_heap_free_bytes Memory that is completely free and eligible to be returned to the underlying system, but has not been. This metric is the runtime's estimate of free address space that is backed by physical memory.
820820
# TYPE go_memory_classes_heap_free_bytes gauge
821821
go_memory_classes_heap_free_bytes 630784

go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/kuadrant/authorino
22

3-
go 1.17
3+
go 1.18
44

55
require (
66
github.com/coocood/freecache v1.1.1

go.sum

-8
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,6 @@ github.com/bugsnag/panicwrap v0.0.0-20151223152923-e2c28503fcd0/go.mod h1:D/8v3k
169169
github.com/bytecodealliance/wasmtime-go v0.36.0 h1:B6thr7RMM9xQmouBtUqm1RpkJjuLS37m6nxX+iwsQSc=
170170
github.com/bytecodealliance/wasmtime-go v0.36.0/go.mod h1:q320gUxqyI8yB+ZqRuaJOEnGkAnHh6WtJjMaT2CW4wI=
171171
github.com/casbin/casbin/v2 v2.1.2/go.mod h1:YcPU1XXisHhLzuxH9coDNf2FbKpjGlbCg3n9yuLkIJQ=
172-
github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4=
173172
github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM=
174173
github.com/cenkalti/backoff/v4 v4.1.0/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw=
175174
github.com/cenkalti/backoff/v4 v4.1.1/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw=
@@ -437,7 +436,6 @@ github.com/franela/goreq v0.0.0-20171204163338-bcd34c9993f8/go.mod h1:ZhphrRTfi2
437436
github.com/frankban/quicktest v1.11.3/go.mod h1:wRf/ReqHper53s+kmmSZizM8NamnL3IM0I9ntUbOk+k=
438437
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
439438
github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ=
440-
github.com/fsnotify/fsnotify v1.5.1/go.mod h1:T3375wBYaZdLLcVNkcVbzGHY7f1l/uK5T5Ai1i3InKU=
441439
github.com/fsnotify/fsnotify v1.5.4 h1:jRbGcIw6P2Meqdwuo0H1p6JVLbL5DHKAKlYndzMwVZI=
442440
github.com/fsnotify/fsnotify v1.5.4/go.mod h1:OVB6XrOHzAwXMpEM7uPOzcehqUV2UqJxmVXmkdnm1bU=
443441
github.com/fullsailor/pkcs7 v0.0.0-20190404230743-d7302db945fa/go.mod h1:KnogPXtdwXqoenmZCw6S+25EAm2MkxbG0deNDu4cbSA=
@@ -837,8 +835,6 @@ github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9k
837835
github.com/onsi/ginkgo v1.15.0/go.mod h1:hF8qUzuuC8DJGygJH3726JnCZX4MYbRB8yFfISqnKUg=
838836
github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vvnwo0=
839837
github.com/onsi/ginkgo v1.16.5 h1:8xi0RTUf59SOSfEtZMvwTvXYMzG4gV23XVHOZiXNtnE=
840-
github.com/onsi/ginkgo v1.16.5/go.mod h1:+E8gABHa3K6zRBolWtd+ROzc/U5bkGt0FwiG042wbpU=
841-
github.com/onsi/ginkgo/v2 v2.0.0/go.mod h1:vw5CSIxN1JObi/U8gcbwft7ZxR2dgaR70JSE3/PpL4c=
842838
github.com/onsi/ginkgo/v2 v2.1.3/go.mod h1:vw5CSIxN1JObi/U8gcbwft7ZxR2dgaR70JSE3/PpL4c=
843839
github.com/onsi/gomega v0.0.0-20151007035656-2152b45fa28a/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA=
844840
github.com/onsi/gomega v0.0.0-20170829124025-dcabb60a477c/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA=
@@ -853,7 +849,6 @@ github.com/onsi/gomega v1.10.5/go.mod h1:gza4q3jKQJijlu05nKWRCW/GavJumGt8aNRxWg7
853849
github.com/onsi/gomega v1.15.0/go.mod h1:cIuvLEne0aoVhAgh/O6ac0Op8WWw9H6eYCriF+tEHG0=
854850
github.com/onsi/gomega v1.17.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAlGdZY=
855851
github.com/onsi/gomega v1.18.1 h1:M1GfJqGRrBrrGGsbxzV5dqM2U2ApXefZCQpkukxYRLE=
856-
github.com/onsi/gomega v1.18.1/go.mod h1:0q+aL8jAiMXy9hbwj2mr5GziHiwhAIQpFmmtT5hitRs=
857852
github.com/op/go-logging v0.0.0-20160315200505-970db520ece7/go.mod h1:HzydrMdWErDVzsI23lYNej1Htcns9BCg93Dk0bBINWk=
858853
github.com/open-policy-agent/opa v0.43.1 h1:GAtUd6aO5lObFP6rRpteXDVffKa4vGUF4I6qVLdhUng=
859854
github.com/open-policy-agent/opa v0.43.1/go.mod h1:xfTsKQEMvy7CxxgsCFoYuzT9jA/8C4JWLignCkN4Dzw=
@@ -1471,7 +1466,6 @@ golang.org/x/sys v0.0.0-20210906170528-6f6e22806c34/go.mod h1:oPkhp1MJrh7nUepCBc
14711466
golang.org/x/sys v0.0.0-20210908233432-aa78b53d3365/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
14721467
golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
14731468
golang.org/x/sys v0.0.0-20211025201205-69cdffdb9359/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
1474-
golang.org/x/sys v0.0.0-20211029165221-6e7872819dc8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
14751469
golang.org/x/sys v0.0.0-20211116061358-0a5406a5449c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
14761470
golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
14771471
golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
@@ -1853,7 +1847,6 @@ k8s.io/gengo v0.0.0-20200428234225-8167cfdcfc14/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8
18531847
k8s.io/gengo v0.0.0-20201113003025-83324d819ded/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E=
18541848
k8s.io/gengo v0.0.0-20210813121822-485abfe95c7c/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E=
18551849
k8s.io/klog v0.0.0-20181102134211-b9b56d5dfc92/go.mod h1:Gq+BEi5rUBO/HRz0bTSXDUcqjScdoY3a9IHpCEIOOfk=
1856-
k8s.io/klog v1.0.0 h1:Pt+yjF5aB1xDSVbau4VsWe+dQNzA0qv1LlXdC2dF6Q8=
18571850
k8s.io/klog v1.0.0/go.mod h1:4Bi6QPql/J/LkTDqv7R/cd3hPo4k2DG6Ptcz060Ez5I=
18581851
k8s.io/klog/v2 v2.0.0/go.mod h1:PBfzABfn139FHAV07az/IF9Wp1bkk3vpT2XSJ76fSDE=
18591852
k8s.io/klog/v2 v2.2.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y=
@@ -1886,7 +1879,6 @@ sigs.k8s.io/controller-runtime v0.11.0 h1:DqO+c8mywcZLFJWILq4iktoECTyn30Bkj0Cwgq
18861879
sigs.k8s.io/controller-runtime v0.11.0/go.mod h1:KKwLiTooNGu+JmLZGn9Sl3Gjmfj66eMbCQznLP5zcqA=
18871880
sigs.k8s.io/json v0.0.0-20211020170558-c049b76a60c6 h1:fD1pz4yfdADVNfFmcP2aBEtudwUQ1AlLnRBALr33v3s=
18881881
sigs.k8s.io/json v0.0.0-20211020170558-c049b76a60c6/go.mod h1:p4QtZmO4uMYipTQNzagwnNoseA6OxSUutVw05NhYDRs=
1889-
sigs.k8s.io/structured-merge-diff v0.0.0-20190525122527-15d366b2352e h1:4Z09Hglb792X0kfOBBJUPFEyvVfQWrYT/l8h5EKA6JQ=
18901882
sigs.k8s.io/structured-merge-diff v0.0.0-20190525122527-15d366b2352e/go.mod h1:wWxsB5ozmmv/SG7nM11ayaAW51xMvak/t1r0CSlcokI=
18911883
sigs.k8s.io/structured-merge-diff/v4 v4.0.1/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw=
18921884
sigs.k8s.io/structured-merge-diff/v4 v4.0.2/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw=

0 commit comments

Comments
 (0)