Skip to content

Commit

Permalink
Merge pull request #41 from lobziik/merge-30-09-2022
Browse files Browse the repository at this point in the history
OCPBUGS-1413: Rebase 30.09.2022 k8s 1.25
  • Loading branch information
openshift-merge-robot committed Oct 3, 2022
2 parents 3d22fae + 1828ca4 commit c15732f
Show file tree
Hide file tree
Showing 865 changed files with 86,007 additions and 53,124 deletions.
6 changes: 1 addition & 5 deletions .golangci.yml
@@ -1,6 +1,6 @@
# ******************************************************************************
# IBM Cloud Kubernetes Service, 5737-D43
# (C) Copyright IBM Corp. 2021 All Rights Reserved.
# (C) Copyright IBM Corp. 2022 All Rights Reserved.
#
# SPDX-License-Identifier: Apache2.0
#
Expand All @@ -19,16 +19,12 @@
linters:
disable-all: true
enable:
- golint
- gofmt
- gosec
- gosimple
- staticcheck
- unused
- govet
- misspell
- varcheck
- structcheck
- ineffassign
- deadcode
- gocritic
8 changes: 4 additions & 4 deletions .travis.yml
Expand Up @@ -19,7 +19,7 @@
language: go

go:
- 1.18.1
- 1.19.1

dist: bionic

Expand Down Expand Up @@ -87,12 +87,12 @@ deploy:
skip_cleanup: true
on:
tags: true
condition: ${TRAVIS_TAG} == v1.24.0-* && ${BUILD_JOB_NAME} == Default
go: 1.18.1
condition: ${TRAVIS_TAG} == v1.25.2-* && ${BUILD_JOB_NAME} == Default
go: 1.19.1
- provider: script
script: BUILD_TAG=${TRAVIS_TAG} make deploy
skip_cleanup: true
on:
tags: true
go: 1.18.1
go: 1.19.1
condition: ${TRAVIS_TAG} == dev-* && ${BUILD_JOB_NAME} == Default
8 changes: 4 additions & 4 deletions Makefile
Expand Up @@ -45,14 +45,14 @@ YAML_FILES=$(shell find . -type f -name '*.y*ml' -not -path "./build-tools/*" -n
INI_FILES=$(shell find . -type f -name '*.ini' -not -path "./build-tools/*")
OSS_FILES := go.mod

GOLANGCI_LINT_VERSION := 1.45.0
GOLANGCI_LINT_VERSION := 1.49.0
GOLANGCI_LINT_EXISTS := $(shell golangci-lint --version 2>/dev/null)

HUB_RLS ?= 2.14.2
REGISTRY ?= armada-master
TAG ?= v1.24.0
TAG ?= v1.25.2

NANCY_VERSION := 1.0.17
NANCY_VERSION := 1.0.37

WORKSPACE=$(GOPATH)/src/k8s.io

Expand Down Expand Up @@ -168,7 +168,7 @@ fvttest:
.PHONY: runanalyzedeps
runanalyzedeps:
which nancy || $(MAKE) install-nancy-dep-scanner
if ! go list -json -m all | nancy sleuth; then scripts/open_depcheck_issue.sh; fi
go list -json -deps | nancy sleuth --no-color > nancy.log 2>&1; scripts/process_nancy_log.sh $$?

.PHONY: install-nancy-dep-scanner
install-nancy-dep-scanner:
Expand Down
70 changes: 12 additions & 58 deletions README.md
Expand Up @@ -6,16 +6,24 @@ infrastructure node and load balancer support to
[Kubernetes](https://kubernetes.io/docs/home/) or
[OpenShift](https://docs.openshift.com/) clusters running on
[IBM Cloud](https://cloud.ibm.com/docs). This repository branch is based on
[Kubernetes version v1.24.0](https://github.com/kubernetes/kubernetes/tree/v1.24.0).
[Kubernetes version v1.25.2](https://github.com/kubernetes/kubernetes/tree/v1.25.2).
See [CONTRIBUTING.md](./CONTRIBUTING.md) for contribution guidelines.

## Local Build and Deploy Instructions

### Building IBM Cloud Provider from your Local Repository

These build instructions have been verified using
[VirtualBox version 6.1.18](https://www.virtualbox.org/wiki/Downloads),
[Vagrant version 2.2.14](https://www.vagrantup.com/downloads) and MacOS version 11.4.
[VirtualBox version 6.1.36](https://www.virtualbox.org/wiki/Downloads),
[Vagrant version 2.2.19](https://www.vagrantup.com/downloads), and
MacOS version 12.5.

1. Create VirtualBox network configuration `/etc/vbox/network.conf` with the following content:

```bash
$ cat /etc/vbox/network.conf
* 192.168.10.0/21 192.168.56.0/21
```

1. Change to your local repository. The build will work against this directory
by making it a vagrant folder synchronized to the VM.
Expand Down Expand Up @@ -94,61 +102,7 @@ new or updated dependencies. You can do this by running `make updatedeps`.

## Kubernetes Version Update Process

The following steps are required to create a new or update an existing branch
for a new Kubernetes version.

1. If the update is for a new Kubernetes major or minor version, select the
current branch from which the new branch will be created. Then
in the `Find or create a branch...` field under the `Branch` drop-down menu,
enter the new branch name `release-<major>.<minor>` where `<major>.<minor>`
is the Kubernetes major and minor version (e.g. `release-1.24`).

1. The Travis CI configuration for this repo includes a cron job that runs
every day. If a new Kubernetes patch version is available for a release, the
cron job will automatically open a pull request with the necessary changes
for that patch.

- If the update is for a new Kubernetes major or minor version, this cron job
will have to be enabled in Travis CI. Do the following to enable the job:

1. Navigate to the Travis CI settings page, and locate the `Cron Jobs` section.
1. Beneath the list of current cron configurations, create a new
configuration with these specifications:
- Branch: `release-<major>.<minor>` (e.g. `release-1.24`)
- Interval: `Daily`
- Options: `Always Run`
1. Click `Add`

- This task can also be run manually to skip having to wait for the cron job
to trigger. Running the following steps will create the PR:

1. `cd vagrant-kube-build`
1. `./build.sh make kube-update KUBE_VERSION=vX.Y.Z` (e.g `v1.24.0`)
1. Go to the URL displayed in the build output to create the pull request.

1. go.mod and go.sum dependencies are kept up to date with the
[renovate](https://docs.renovatebot.com/golang/) application.
One or more pull requests with the necessary changes will be created
and must be reviewed and merged.

1. If the current branch is the latest branch, update this repository's branch
settings to make it the default branch.

1. If the update is for a new Kubernetes major or minor version, update the
[IBM CCM base image](./cmd/ibm-cloud-controller-manager/Dockerfile)
if an update is available.

1. If the update is for a new Kubernetes major or minor version, open a PR to
update the golangci-lint version in `.travis.yml` to use the latest release.
Available releases can be found [here](https://github.com/golangci/golangci-lint/releases).
You may need to make changes to the code to achieve compliance with the
latest linting version.

1. If the update is for a new Kubernetes major or minor version, update the
nightly build job to include the branch in the releases to tag. Ensure the
job is rebuilt with the changes before proceeding to the next step.

1. Once all PRs are merged, follow the [release process](#release-process) to build the IBM Cloud Provider for the update.
The steps needed to support a new Kubernetes release have been moved to a Wiki page.

## Release Process

Expand Down
2 changes: 1 addition & 1 deletion addons/vpcctl.yml
Expand Up @@ -21,7 +21,7 @@
source: github.ibm.com/alchemy-containers/armada-vpc-lb

# (Required) - git release or branch name in the source github repo
release: v0.6.0
release: v0.7.1

# (Required) - source directory in the github repo containing GO files
source_dir: pkg/vpcctl
Expand Down
2 changes: 1 addition & 1 deletion cmd/ibm-cloud-controller-manager/Dockerfile
Expand Up @@ -24,7 +24,7 @@
# distroless images, see https://github.com/GoogleContainerTools/distroless.
# The Kubernetes version update process will keep this image up-to-date.
ARG IMAGE_SOURCE=gcr.io
FROM $IMAGE_SOURCE/distroless/static@sha256:2556293984c5738fc75208cce52cf0a4762c709cf38e4bf8def65a61992da0ad
FROM $IMAGE_SOURCE/distroless/static@sha256:2a9e2b4fa771d31fe3346a873be845bfc2159695b9f90ca08e950497006ccc2e

# Add Labels to image to show build details
ARG this_build_id=unknown
Expand Down
2 changes: 1 addition & 1 deletion docs/examples/ibm-cloud-controller-manager.yaml
Expand Up @@ -70,7 +70,7 @@ spec:
terminationGracePeriodSeconds: 90
containers:
- name: ibm-cloud-controller-manager
image: registry.ng.bluemix.net/armada-master/ibm-cloud-controller-manager:v1.24.0-1
image: registry.ng.bluemix.net/armada-master/ibm-cloud-controller-manager:v1.25.2-1
imagePullPolicy: IfNotPresent
securityContext:
runAsNonRoot: true
Expand Down
82 changes: 38 additions & 44 deletions go.mod
Expand Up @@ -3,21 +3,22 @@ module cloud.ibm.com/cloud-provider-ibm
go 1.18

require (
github.com/IBM/go-sdk-core/v5 v5.9.5
github.com/IBM/platform-services-go-sdk v0.25.0
github.com/IBM/vpc-go-sdk v0.19.0
github.com/go-openapi/strfmt v0.21.2
github.com/spf13/cobra v1.4.0
github.com/IBM/go-sdk-core/v5 v5.10.2
github.com/IBM/platform-services-go-sdk v0.28.4
github.com/IBM/vpc-go-sdk v0.26.0
github.com/fsnotify/fsnotify v1.5.4
github.com/go-openapi/strfmt v0.21.3
github.com/spf13/cobra v1.5.0
github.com/spf13/pflag v1.0.5
github.com/stretchr/testify v1.7.1
github.com/stretchr/testify v1.8.0
gopkg.in/gcfg.v1 v1.2.3
k8s.io/api v0.24.0
k8s.io/apimachinery v0.24.0
k8s.io/client-go v0.24.0
k8s.io/cloud-provider v0.24.0
k8s.io/component-base v0.24.0
k8s.io/klog/v2 v2.60.1
k8s.io/utils v0.0.0-20220210201930-3a6ce19ff2f9
k8s.io/api v0.25.2
k8s.io/apimachinery v0.25.2
k8s.io/client-go v0.25.2
k8s.io/cloud-provider v0.25.2
k8s.io/component-base v0.25.2
k8s.io/klog/v2 v2.80.1
k8s.io/utils v0.0.0-20220728103510-ee6ede2d64ed
)

require (
Expand All @@ -32,29 +33,27 @@ require (
github.com/coreos/go-semver v0.3.0 // indirect
github.com/coreos/go-systemd/v22 v22.3.2 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/emicklei/go-restful v2.9.6+incompatible // indirect
github.com/emicklei/go-restful/v3 v3.8.0 // indirect
github.com/evanphx/json-patch v4.12.0+incompatible // indirect
github.com/felixge/httpsnoop v1.0.1 // indirect
github.com/fsnotify/fsnotify v1.4.9 // indirect
github.com/go-logr/logr v1.2.0 // indirect
github.com/go-openapi/errors v0.20.1 // indirect
github.com/go-logr/logr v1.2.3 // indirect
github.com/go-openapi/errors v0.20.2 // indirect
github.com/go-openapi/jsonpointer v0.19.5 // indirect
github.com/go-openapi/jsonreference v0.19.6 // indirect
github.com/go-openapi/swag v0.19.15 // indirect
github.com/go-playground/locales v0.14.0 // indirect
github.com/go-playground/universal-translator v0.18.0 // indirect
github.com/go-stack/stack v1.8.1 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/golang/protobuf v1.5.2 // indirect
github.com/google/gnostic v0.5.7-v3refs // indirect
github.com/google/go-cmp v0.5.6 // indirect
github.com/google/go-cmp v0.5.8 // indirect
github.com/google/gofuzz v1.1.0 // indirect
github.com/google/uuid v1.3.0 // indirect
github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 // indirect
github.com/grpc-ecosystem/grpc-gateway v1.16.0 // indirect
github.com/hashicorp/go-cleanhttp v0.5.2 // indirect
github.com/hashicorp/go-retryablehttp v0.7.0 // indirect
github.com/hashicorp/go-retryablehttp v0.7.1 // indirect
github.com/imdario/mergo v0.3.12 // indirect
github.com/inconshreveable/mousetrap v1.0.0 // indirect
github.com/josharian/intern v1.0.0 // indirect
Expand All @@ -74,10 +73,10 @@ require (
github.com/prometheus/client_model v0.2.0 // indirect
github.com/prometheus/common v0.32.1 // indirect
github.com/prometheus/procfs v0.7.3 // indirect
go.etcd.io/etcd/api/v3 v3.5.1 // indirect
go.etcd.io/etcd/client/pkg/v3 v3.5.1 // indirect
go.etcd.io/etcd/client/v3 v3.5.1 // indirect
go.mongodb.org/mongo-driver v1.7.5 // indirect
go.etcd.io/etcd/api/v3 v3.5.4 // indirect
go.etcd.io/etcd/client/pkg/v3 v3.5.4 // indirect
go.etcd.io/etcd/client/v3 v3.5.4 // indirect
go.mongodb.org/mongo-driver v1.10.0 // indirect
go.opentelemetry.io/contrib v0.20.0 // indirect
go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.20.0 // indirect
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.20.0 // indirect
Expand All @@ -92,35 +91,30 @@ require (
go.uber.org/atomic v1.7.0 // indirect
go.uber.org/multierr v1.6.0 // indirect
go.uber.org/zap v1.19.0 // indirect
golang.org/x/crypto v0.0.0-20220214200702-86341886e292 // indirect
golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd // indirect
golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d // indirect
golang.org/x/net v0.0.0-20220722155237-a158d28d115b // indirect
golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8 // indirect
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c // indirect
golang.org/x/sys v0.0.0-20220330033206-e17cdc41300f // indirect
golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4 // indirect
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f // indirect
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211 // indirect
golang.org/x/text v0.3.7 // indirect
golang.org/x/time v0.0.0-20220210224613-90d013bbcef8 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/genproto v0.0.0-20220107163113-42d7afdf6368 // indirect
google.golang.org/grpc v1.40.0 // indirect
google.golang.org/protobuf v1.27.1 // indirect
google.golang.org/genproto v0.0.0-20220502173005-c8bf987b8c21 // indirect
google.golang.org/grpc v1.47.0 // indirect
google.golang.org/protobuf v1.28.0 // indirect
gopkg.in/go-playground/validator.v9 v9.31.0 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/natefinch/lumberjack.v2 v2.0.0 // indirect
gopkg.in/warnings.v0 v0.1.2 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b // indirect
k8s.io/apiserver v0.24.0 // indirect
k8s.io/component-helpers v0.24.0 // indirect
k8s.io/controller-manager v0.24.0 // indirect
k8s.io/kube-openapi v0.0.0-20220328201542-3ee0da9b0b42 // indirect
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.30 // indirect
sigs.k8s.io/json v0.0.0-20211208200746-9f7c6b3444d2 // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.2.1 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/apiserver v0.25.2 // indirect
k8s.io/component-helpers v0.25.2 // indirect
k8s.io/controller-manager v0.25.2 // indirect
k8s.io/kube-openapi v0.0.0-20220803162953-67bda5d908f1 // indirect
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.32 // indirect
sigs.k8s.io/json v0.0.0-20220713155537-f223a00ba0e2 // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect
sigs.k8s.io/yaml v1.2.0 // indirect
)

replace github.com/coreos/etcd => github.com/coreos/etcd v3.3.25+incompatible

// Use forked version of library with security fix cherry-picked
replace github.com/dgrijalva/jwt-go v3.2.0+incompatible => github.com/form3tech-oss/jwt-go v3.2.1+incompatible

0 comments on commit c15732f

Please sign in to comment.