openshift / vertical-pod-autoscaler-operator

An Operator for running the Vertical Pod Autoscaler on OpenShift
Apache License 2.0
27 stars 30 forks source link

PODAUTO-199: Updates for 4.17 #167

Closed maxcao13 closed 3 months ago

maxcao13 commented 3 months ago

Updates for 4.17

Had to update some struct initialization and func arguments because of a controller-runtime upgrade to v18.4 from v17.0 https://github.com/kubernetes-sigs/controller-runtime/pull/2783

openshift-ci-robot commented 3 months ago

@maxcao13: This pull request references PODAUTO-199 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.17.0" version, but no target version was set.

In response to [this](https://github.com/openshift/vertical-pod-autoscaler-operator/pull/167): >Updates for 4.16 > >* Update deps > * edit (update to 4.17/0.30.2) and run `hack/update-vendor.sh` >* Update code and build to match updated deps > * Update go version to go 1.22 (go.mod, Dockerfile, images/ci/Dockerfile, Makefile) (_cannot update vet/lint/upstream-manifest because openshift/release doesnt seem to have 1.22 tag yet_) > * Rev version from 4.16 -> 4.17: `sed -i 's/4.16/4.17/g' $(git grep -l 4.15 manifests/) images/ci/bundle.Dockerfile hack/manifest-diff-upstream.sh hack/e2e.sh Makefile` > * Verify that Dockerfile.rhel7 & .ci-operator.yaml are up to date (they are. [Thanks, ART team](https://github.com/openshift/vertical-pod-autoscaler-operator/pull/163)!) >* Update manifests to match upstream > >Had to update some struct initialization and func arguments because of a `controller-runtime` upgrade to v18.4 from v17.0 https://github.com/kubernetes-sigs/controller-runtime/pull/2783 Instructions for interacting with me using PR comments are available [here](https://prow.ci.openshift.org/command-help?repo=openshift%2Fvertical-pod-autoscaler-operator). If you have questions or suggestions related to my behavior, please file an issue against the [openshift-eng/jira-lifecycle-plugin](https://github.com/openshift-eng/jira-lifecycle-plugin/issues/new) repository.
joelsmith commented 3 months ago

As discussed on Slack, sed -i 's/4.16/4.17/g' $(git grep -l 4.15 manifests/) should have been sed -i 's/4.16/4.17/g' $(git grep -l 4.16 manifests/)

Nice work on the controller runtime related updates!

I think maybe it's time to move off of the openshift/origin-release:golang-1.XX and registry.ci.openshift.org/openshift/release:golang-1.XX images and use the registry.ci.openshift.org/ocp/builder:rhel-9-golang-1.XX-openshift-4.YY images since those seem to be updated regularly while the others don't.

Would you mind switching the images in the following files as part of this update?

Makefile
hack/go-fmt.sh
hack/go-lint.sh
hack/go-vet.sh
hack/manifest-diff-upstream.sh
hack/manifest-diff.sh
maxcao13 commented 3 months ago

I was looking at it, should golint and its scripts + ci yamls still exist? It seems to be deprecated in favour of go vet and Staticcheck https://github.com/golang/lint

openshift-ci-robot commented 3 months ago

@maxcao13: This pull request references PODAUTO-199 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.17.0" version, but no target version was set.

In response to [this](https://github.com/openshift/vertical-pod-autoscaler-operator/pull/167): >Updates for 4.17 > >* Update deps > * edit (update to 4.17/0.30.2) and run `hack/update-vendor.sh` >* Update code and build to match updated deps > * Update go version to go 1.22 (go.mod, Dockerfile, images/ci/Dockerfile, Makefile) (_cannot update vet/lint/upstream-manifest because openshift/release doesnt seem to have 1.22 tag yet_) > * Rev version from 4.16 -> 4.17: `sed -i 's/4.16/4.17/g' $(git grep -l 4.16 manifests/) images/ci/bundle.Dockerfile hack/manifest-diff-upstream.sh hack/e2e.sh Makefile` > * Verify that Dockerfile.rhel7 & .ci-operator.yaml are up to date (they are. [Thanks, ART team](https://github.com/openshift/vertical-pod-autoscaler-operator/pull/163)!) >* Update manifests to match upstream > >Had to update some struct initialization and func arguments because of a `controller-runtime` upgrade to v18.4 from v17.0 https://github.com/kubernetes-sigs/controller-runtime/pull/2783 Instructions for interacting with me using PR comments are available [here](https://prow.ci.openshift.org/command-help?repo=openshift%2Fvertical-pod-autoscaler-operator). If you have questions or suggestions related to my behavior, please file an issue against the [openshift-eng/jira-lifecycle-plugin](https://github.com/openshift-eng/jira-lifecycle-plugin/issues/new) repository.
openshift-ci-robot commented 3 months ago

@maxcao13: This pull request references PODAUTO-199 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.17.0" version, but no target version was set.

In response to [this](https://github.com/openshift/vertical-pod-autoscaler-operator/pull/167): >Updates for 4.17 > >* Update deps > * edit (update to 4.17/0.30.2) and run `hack/update-vendor.sh` >* Update code and build to match updated deps > * Update go version to go 1.22 (go.mod, Dockerfile, images/ci/Dockerfile, Makefile) > * Switched from old images to updated `registry.ci.openshift.org/ocp/builder:rhel-9-golang-1.22-openshift-4.17` in go-fmt, go-vet, Makefile, etc... > * Rev version from 4.16 -> 4.17: `sed -i 's/4.16/4.17/g' $(git grep -l 4.16 manifests/) images/ci/bundle.Dockerfile hack/manifest-diff-upstream.sh hack/e2e.sh Makefile` > * Verify that Dockerfile.rhel7 & .ci-operator.yaml are up to date (they are. [Thanks, ART team](https://github.com/openshift/vertical-pod-autoscaler-operator/pull/163)!) >* Update manifests to match upstream > >Had to update some struct initialization and func arguments because of a `controller-runtime` upgrade to v18.4 from v17.0 https://github.com/kubernetes-sigs/controller-runtime/pull/2783 Instructions for interacting with me using PR comments are available [here](https://prow.ci.openshift.org/command-help?repo=openshift%2Fvertical-pod-autoscaler-operator). If you have questions or suggestions related to my behavior, please file an issue against the [openshift-eng/jira-lifecycle-plugin](https://github.com/openshift-eng/jira-lifecycle-plugin/issues/new) repository.
maxcao13 commented 3 months ago

Seems like registry.ci.openshift.org/ocp/builder:rhel-9-golang-1.22-openshift-4.17 doesn't include jq and that causes manifest-diff*.sh scripts to fail.

maxcao13 commented 3 months ago

Updated with new release images.

openshift-ci-robot commented 3 months ago

@maxcao13: This pull request references PODAUTO-199 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.17.0" version, but no target version was set.

In response to [this](https://github.com/openshift/vertical-pod-autoscaler-operator/pull/167): >Updates for 4.17 > >* Update deps > * edit (update to 4.17/0.30.2) and run `hack/update-vendor.sh` >* Update code and build to match updated deps > * Update go version to go 1.22 (go.mod, Dockerfile, images/ci/Dockerfile, Makefile) > * Switched from old images to updated ci tooling images `registry.ci.openshift.org/openshift/release:rhel-9-release-golang-1.22-openshift-4.17` in go-fmt, go-vet, Makefile, etc... > * Rev version from 4.16 -> 4.17: `sed -i 's/4.16/4.17/g' $(git grep -l 4.16 manifests/) images/ci/bundle.Dockerfile hack/manifest-diff-upstream.sh hack/e2e.sh Makefile` > * Verify that Dockerfile.rhel7 & .ci-operator.yaml are up to date (they are. [Thanks, ART team](https://github.com/openshift/vertical-pod-autoscaler-operator/pull/163)!) >* Update manifests to match upstream > >Had to update some struct initialization and func arguments because of a `controller-runtime` upgrade to v18.4 from v17.0 https://github.com/kubernetes-sigs/controller-runtime/pull/2783 Instructions for interacting with me using PR comments are available [here](https://prow.ci.openshift.org/command-help?repo=openshift%2Fvertical-pod-autoscaler-operator). If you have questions or suggestions related to my behavior, please file an issue against the [openshift-eng/jira-lifecycle-plugin](https://github.com/openshift-eng/jira-lifecycle-plugin/issues/new) repository.
openshift-ci-robot commented 3 months ago

@maxcao13: This pull request references PODAUTO-199 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.17.0" version, but no target version was set.

In response to [this](https://github.com/openshift/vertical-pod-autoscaler-operator/pull/167): >Updates for 4.17 > >* Update deps > * edit (update to 4.17/0.30.2) and run `hack/update-vendor.sh` >* Update code and build to match updated deps > * Update go version to go 1.22 (go.mod, Dockerfile, images/ci/Dockerfile, Makefile) > * Switched from old images to updated ci tooling images `registry.ci.openshift.org/openshift/release:rhel-9-release-golang-1.22-openshift-4.17` in go-fmt, go-vet, Makefile, etc... > * Rev version from 4.16 -> 4.17: `sed -i 's/4.16/4.17/g' $(git grep -l 4.16 manifests/) images/ci/bundle.Dockerfile hack/manifest-diff-upstream.sh hack/e2e.sh Makefile` > * Verify that Dockerfile.rhel7 & .ci-operator.yaml are up to date (they are. [Thanks, ART team](https://github.com/openshift/vertical-pod-autoscaler-operator/pull/163)!) >* Update manifests to match upstream >* Updated ci + release images to `FROM registry.ci.openshift.org/openshift/release:rhel-9-release-golang-1.22-openshift-4.17` >* Updated ci base image from `openshift/origin-v4.0` to `registry.ci.openshift.org/ocp/4.17:base-rhel9` > > >Had to update some struct initialization and func arguments because of a `controller-runtime` upgrade to v18.4 from v17.0 https://github.com/kubernetes-sigs/controller-runtime/pull/2783 Instructions for interacting with me using PR comments are available [here](https://prow.ci.openshift.org/command-help?repo=openshift%2Fvertical-pod-autoscaler-operator). If you have questions or suggestions related to my behavior, please file an issue against the [openshift-eng/jira-lifecycle-plugin](https://github.com/openshift-eng/jira-lifecycle-plugin/issues/new) repository.
maxcao13 commented 3 months ago

Included PODAUTO-202 changes in this PR.

EDIT: Although, I'm not sure if the Dockerfile in images/ci/Dockerfile is actually being used anywhere. Here's the current config in openshift/release: https://github.com/openshift/release/blob/17ca3ef1f06212c127e5ea483b9a4d825370aeeb/ci-operator/config/openshift/vertical-pod-autoscaler-operator/openshift-vertical-pod-autoscaler-operator-master.yaml Does anyone happen to know?

openshift-ci-robot commented 3 months ago

@maxcao13: This pull request references PODAUTO-199 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.17.0" version, but no target version was set.

In response to [this](https://github.com/openshift/vertical-pod-autoscaler-operator/pull/167): >Updates for 4.17 > >* Update deps > * edit (update to 4.17/0.30.2) and run `hack/update-vendor.sh` >* Update code and build to match updated deps > * Update go version to go 1.22 (go.mod, Dockerfile, images/ci/Dockerfile, Makefile) > * Switched from old images to updated ci tooling images `registry.ci.openshift.org/openshift/release:rhel-9-release-golang-1.22-openshift-4.17` in go-fmt, go-vet, Makefile, etc... > * Rev version from 4.16 -> 4.17: `sed -i 's/4.16/4.17/g' $(git grep -l 4.16 manifests/) images/ci/bundle.Dockerfile hack/manifest-diff-upstream.sh hack/e2e.sh Makefile` > * Verify that Dockerfile.rhel7 & .ci-operator.yaml are up to date (they are. [Thanks, ART team](https://github.com/openshift/vertical-pod-autoscaler-operator/pull/163)!) >* Update manifests to match upstream >* Updated ci + release images to `FROM registry.ci.openshift.org/openshift/release:rhel-9-release-golang-1.22-openshift-4.17` (`images/ci/Dockerfile`,`images/operator-registry/Dockerfile.registry.ci`, `Dockerfile`, `Dockerfile.rhel`) >* Updated ci base image from `openshift/origin-v4.0` to `registry.ci.openshift.org/ocp/4.17:base-rhel9` > > >Had to update some struct initialization and func arguments because of a `controller-runtime` upgrade to v18.4 from v17.0 https://github.com/kubernetes-sigs/controller-runtime/pull/2783 Instructions for interacting with me using PR comments are available [here](https://prow.ci.openshift.org/command-help?repo=openshift%2Fvertical-pod-autoscaler-operator). If you have questions or suggestions related to my behavior, please file an issue against the [openshift-eng/jira-lifecycle-plugin](https://github.com/openshift-eng/jira-lifecycle-plugin/issues/new) repository.
openshift-ci[bot] commented 3 months ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: joelsmith, maxcao13

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files: - ~~[OWNERS](https://github.com/openshift/vertical-pod-autoscaler-operator/blob/master/OWNERS)~~ [joelsmith] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
openshift-ci[bot] commented 3 months ago

@maxcao13: all tests passed!

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes-sigs/prow](https://github.com/kubernetes-sigs/prow/issues/new?title=Prow%20issue:) repository. I understand the commands that are listed [here](https://go.k8s.io/bot-commands).
openshift-bot commented 3 months ago

[ART PR BUILD NOTIFIER]

Distgit: vertical-pod-autoscaler-operator This PR has been included in build ose-vertical-pod-autoscaler-operator-container-v4.18.0-202407232010.p0.gd0b168e.assembly.stream.el9. All builds following this will include this PR.