Skip to content

Commit 9b6c844

Browse files
authored
use go 1.20 (#2149)
* use go 1.20 * remove rand seed
1 parent 68c2b3a commit 9b6c844

File tree

4 files changed

+4
-8
lines changed

4 files changed

+4
-8
lines changed

Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,15 @@
1414
## BUILD ARGS ##
1515
################################################################################
1616
# This build arg allows the specification of a custom Golang image.
17-
ARG GOLANG_IMAGE=golang:1.19.6
17+
ARG GOLANG_IMAGE=golang:1.20.1
1818

1919
# The distroless image on which the CPI manager image is built.
2020
#
2121
# Please do not use "latest". Explicit tags should be used to provide
2222
# deterministic builds. Follow what kubernetes uses to build
2323
# kube-controller-manager, for example for 1.23.x:
2424
# https://github.com/kubernetes/kubernetes/blob/release-1.24/build/common.sh#L94
25-
ARG DISTROLESS_IMAGE=k8s.gcr.io/build-image/go-runner:v2.3.1-go1.19.6-bullseye.0
25+
ARG DISTROLESS_IMAGE=k8s.gcr.io/build-image/go-runner:v2.3.1-go1.20.1-bullseye.0
2626

2727
# We use Alpine as the source for default CA certificates and some output
2828
# images

cmd/openstack-cloud-controller-manager/main.go

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,7 @@ package main
2222
import (
2323
goflag "flag"
2424
"fmt"
25-
"math/rand"
2625
"os"
27-
"time"
2826

2927
"github.com/spf13/pflag"
3028
"k8s.io/apimachinery/pkg/util/wait"
@@ -44,8 +42,6 @@ import (
4442
)
4543

4644
func main() {
47-
rand.Seed(time.Now().UnixNano())
48-
4945
ccmOptions, err := options.NewCloudControllerManagerOptions()
5046
if err != nil {
5147
klog.Fatalf("unable to initialize command options: %v", err)

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module k8s.io/cloud-provider-openstack
22

3-
go 1.19
3+
go 1.20
44

55
replace github.com/onsi/ginkgo/v2 => github.com/onsi/ginkgo/v2 v2.4.0
66

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
go_version: '1.19'
2+
go_version: '1.20'
33
arch: 'amd64'
44
go_tarball: 'go{{ go_version }}.linux-{{ arch }}.tar.gz'
55
go_download_location: 'https://go.dev/dl/{{ go_tarball }}'

0 commit comments

Comments
 (0)