From 6a2a099b70374bc05e4b01de92ff981be735185a Mon Sep 17 00:00:00 2001 From: Anjan Nath Date: Thu, 28 Sep 2023 18:29:22 +0530 Subject: [PATCH] update to go 1.20 --- .github/workflows/choco-release.yml | 2 +- .github/workflows/macos-installer.yml | 2 +- .github/workflows/make-check-win.yml | 2 +- .github/workflows/make-check.yml | 2 +- .github/workflows/make-rpm.yml | 2 +- .github/workflows/windows-chocolatey.yml | 2 +- .github/workflows/windows-installer.yml | 2 +- go.mod | 2 +- pkg/crc/cluster/podman.go | 4 ++-- 9 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/choco-release.yml b/.github/workflows/choco-release.yml index 747dda20a2..3c628713ab 100644 --- a/.github/workflows/choco-release.yml +++ b/.github/workflows/choco-release.yml @@ -13,7 +13,7 @@ jobs: os: - windows-2022 go: - - 1.19 + - 1.20 steps: - name: Check out repository code uses: actions/checkout@v3 diff --git a/.github/workflows/macos-installer.yml b/.github/workflows/macos-installer.yml index 1d1feac116..da2bcf6237 100644 --- a/.github/workflows/macos-installer.yml +++ b/.github/workflows/macos-installer.yml @@ -20,7 +20,7 @@ jobs: - macOS-latest - macOS-11 go: - - 1.19 + - 1.20 steps: # Enable tmate debugging of manually-triggered workflows if the input option was provided - name: Setup tmate session diff --git a/.github/workflows/make-check-win.yml b/.github/workflows/make-check-win.yml index d5f7e46de8..4ba69006e7 100644 --- a/.github/workflows/make-check-win.yml +++ b/.github/workflows/make-check-win.yml @@ -14,7 +14,7 @@ jobs: - windows-2019 - windows-2022 go: - - 1.19 + - 1.20 steps: - name: Check out repository code uses: actions/checkout@v3 diff --git a/.github/workflows/make-check.yml b/.github/workflows/make-check.yml index 242596c472..d9520722af 100644 --- a/.github/workflows/make-check.yml +++ b/.github/workflows/make-check.yml @@ -16,7 +16,7 @@ jobs: - ubuntu-latest - ubuntu-20.04 go: - - 1.19 + - 1.20 steps: - name: Check out repository code uses: actions/checkout@v3 diff --git a/.github/workflows/make-rpm.yml b/.github/workflows/make-rpm.yml index 5fb344aa54..fb935b616f 100644 --- a/.github/workflows/make-rpm.yml +++ b/.github/workflows/make-rpm.yml @@ -13,7 +13,7 @@ jobs: os: - ubuntu-latest go: - - 1.19 + - 1.20 steps: - name: Check out repository code uses: actions/checkout@v3 diff --git a/.github/workflows/windows-chocolatey.yml b/.github/workflows/windows-chocolatey.yml index 5f09e559e7..3256185c81 100755 --- a/.github/workflows/windows-chocolatey.yml +++ b/.github/workflows/windows-chocolatey.yml @@ -13,7 +13,7 @@ jobs: os: - windows-2022 go: - - 1.19 + - 1.20 steps: - name: Check out repository code uses: actions/checkout@v3 diff --git a/.github/workflows/windows-installer.yml b/.github/workflows/windows-installer.yml index 357a052293..e61efbb228 100644 --- a/.github/workflows/windows-installer.yml +++ b/.github/workflows/windows-installer.yml @@ -14,7 +14,7 @@ jobs: - windows-2019 - windows-2022 go: - - 1.19 + - 1.20 steps: - name: Check out repository code uses: actions/checkout@v3 diff --git a/go.mod b/go.mod index 3ca3dcfcee..82fbf3ea30 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/crc-org/crc/v2 -go 1.19 +go 1.20 require ( github.com/AlecAivazis/survey/v2 v2.3.7 diff --git a/pkg/crc/cluster/podman.go b/pkg/crc/cluster/podman.go index acbcd721fb..3f083f2a49 100644 --- a/pkg/crc/cluster/podman.go +++ b/pkg/crc/cluster/podman.go @@ -7,12 +7,12 @@ import ( ) func GenerateCockpitBearerToken() string { - rand.Seed(time.Now().UnixNano()) + rng := rand.NewSource(time.Now().UnixNano()) const letterBytes = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ" b := make([]byte, 8) for i := range b { - b[i] = letterBytes[rand.Int63()%int64(len(letterBytes))] // #nosec + b[i] = letterBytes[rng.Int63()%int64(len(letterBytes))] // #nosec } return base64.StdEncoding.EncodeToString(b) }