Skip to content

Commit

Permalink
Update to Go 1.19
Browse files Browse the repository at this point in the history
ref: stolostron/backlog#26059
Signed-off-by: Dale Haiducek <dhaiduce@redhat.com>
dhaiducek authored and openshift-merge-robot committed Oct 13, 2022
1 parent 2fa7bf1 commit 7088232
Showing 3 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion build/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Stage 1: Use image builder to build the target binaries
# Copyright Contributors to the Open Cluster Management project

FROM golang:1.18 AS builder
FROM golang:1.19 AS builder

ENV COMPONENT=governance-policy-framework-addon
ENV REPO_PATH=/go/src/github.com/open-cluster-management-io/${COMPONENT}
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module open-cluster-management.io/governance-policy-framework-addon

go 1.18
go 1.19

require (
github.com/go-logr/zapr v1.2.3
3 changes: 1 addition & 2 deletions tool/operator-sdk-port.go
Original file line number Diff line number Diff line change
@@ -8,7 +8,6 @@ package tool

import (
"fmt"
"io/ioutil"
"os"
"strings"
)
@@ -39,7 +38,7 @@ func GetOperatorNamespace() (string, error) {
return "", ErrRunLocal
}

nsBytes, err := ioutil.ReadFile("/var/run/secrets/kubernetes.io/serviceaccount/namespace")
nsBytes, err := os.ReadFile("/var/run/secrets/kubernetes.io/serviceaccount/namespace")
if err != nil {
if os.IsNotExist(err) {
return "", ErrNoNamespace

0 comments on commit 7088232

Please sign in to comment.