Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OCPNODE-2098: Add static pod for kube-rbac-proxy-crio #4175

Merged

Conversation

rphillips
Copy link
Contributor

@rphillips rphillips commented Feb 7, 2024

This PR adds a static pod to the MCO to lay down a kube-rbac-proxy to secure crio's metrics port. The TLS endpoints supports cert based authentication for monitoring.

Merge information

After all the above backports are merged, then

This PR will need to be backported to EUS 4.14.

@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Feb 7, 2024
@rphillips rphillips force-pushed the rbac_crio_metrics_static_pod branch 11 times, most recently from 16324c2 to 12bb710 Compare February 8, 2024 20:14
Copy link
Contributor

openshift-ci bot commented Feb 8, 2024

@rphillips: This PR was included in a payload test run from openshift/cluster-monitoring-operator#2257
trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • periodic-ci-openshift-release-master-ci-4.16-upgrade-from-stable-4.15-e2e-aws-ovn-upgrade

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/820f5280-c6d5-11ee-97cb-3e05c7124d92-0

Copy link
Contributor

openshift-ci bot commented Feb 12, 2024

@rphillips: This PR was included in a payload test run from openshift/cluster-monitoring-operator#2257
trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • periodic-ci-openshift-release-master-ci-4.16-upgrade-from-stable-4.15-e2e-aws-ovn-upgrade

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/896bb770-c93d-11ee-8788-320a5f153a65-0

@rphillips rphillips force-pushed the rbac_crio_metrics_static_pod branch 5 times, most recently from d32a2a9 to 410e914 Compare February 12, 2024 17:13
Copy link
Contributor

openshift-ci bot commented Feb 12, 2024

@rphillips: This PR was included in a payload test run from openshift/cluster-monitoring-operator#2257
trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • periodic-ci-openshift-release-master-ci-4.16-upgrade-from-stable-4.15-e2e-aws-ovn-upgrade

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/0d734920-c9ca-11ee-824a-026157b75804-0

Copy link
Contributor

openshift-ci bot commented Feb 13, 2024

@rphillips: This PR was included in a payload test run from openshift/cluster-monitoring-operator#2257
trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • periodic-ci-openshift-release-master-ci-4.16-upgrade-from-stable-4.15-e2e-aws-ovn-upgrade

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/56f50e00-ca7c-11ee-974b-7cd8f62e7155-0

@rphillips rphillips force-pushed the rbac_crio_metrics_static_pod branch 3 times, most recently from 08b787a to 5d99f07 Compare February 13, 2024 18:44
Copy link
Contributor

openshift-ci bot commented Feb 20, 2024

@rphillips: This PR was included in a payload test run from openshift/cluster-monitoring-operator#2257
trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • periodic-ci-openshift-release-master-ci-4.16-upgrade-from-stable-4.15-e2e-aws-ovn-upgrade

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/71d442f0-d03e-11ee-95a3-a9525782e9b1-0

@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Mar 5, 2024

@rphillips: This pull request references OCPNODE-2098 which is a valid jira issue.

In response to this:

/jira refresh

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@rphillips
Copy link
Contributor Author

/cherry-pick release-4.15

@openshift-cherrypick-robot

@rphillips: once the present PR merges, I will cherry-pick it on top of release-4.15 in a new PR and assign it to you.

In response to this:

/cherry-pick release-4.15

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@rphillips
Copy link
Contributor Author

/hold until openshift/origin#28636 merges.

@openshift-ci openshift-ci bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Mar 5, 2024
@rphillips rphillips changed the title OCPNODE-2098: Add static pods for crio rbac proxy OCPNODE-2098: Add static pod for kube-rbac-proxy-crio Mar 5, 2024
@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Mar 5, 2024

@rphillips: This pull request references OCPNODE-2098 which is a valid jira issue.

In response to this:

description incoming...

This PR will need to be backported to EUS 4.14.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@rphillips
Copy link
Contributor Author

/test e2e-aws-ovn

@rphillips
Copy link
Contributor Author

/hold cancel

openshift/origin#28636 merged

@openshift-ci openshift-ci bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Mar 6, 2024
@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Mar 6, 2024

@rphillips: This pull request references OCPNODE-2098 which is a valid jira issue.

In response to this:

This PR adds a static pod to the MCO to lay down a kube-rbac-proxy to secure crio's metrics port. The TLS endpoints supports cert based authentication for monitoring.

Merge information

After all the above backports are merged, then

This PR will need to be backported to EUS 4.14.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Mar 6, 2024

@rphillips: This pull request references OCPNODE-2098 which is a valid jira issue.

In response to this:

This PR adds a static pod to the MCO to lay down a kube-rbac-proxy to secure crio's metrics port. The TLS endpoints supports cert based authentication for monitoring.

Merge information

After all the above backports are merged, then

This PR will need to be backported to EUS 4.14.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

Copy link
Contributor

@harche harche left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Mar 6, 2024
Copy link
Contributor

@cdoern cdoern left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some service account and port questions. but looks good!

ports:
- containerPort: 9637
args:
- --secure-listen-address=:9637
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

any specific reason for this port?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The usual port is 9537. To make it easier to identify the secure port I used 9637 (100 more than the insecure one). (9637 is not in use by the /etc/services file).

- --logtostderr=true
- --kubeconfig=/var/lib/kubelet/kubeconfig
- --tls-cipher-suites=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305,TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305
- --upstream=http://127.0.0.1:9537
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

our kube-rbac-proxy ctrs usually use a different port, I am forgetting which. Should we mimic that here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The kube-rbac-proxy is exposing a host network port (9637) and forwarding to the host's 9537 port. I slightly deviated from the usual construct due to host networking.

path: /metrics
verb: get
user:
name: system:serviceaccount:openshift-monitoring:prometheus-k8s
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this using the openshift-monitoring SA?

In our other kube-rbac-proxy pods we specify which serviceAccountName: we want to use. Where is that happening in this PR?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This new kube-rbac-proxy-crio service does not have access to service account secrets due to being a static pod. Instead, we are using client side certificate validation and only allowing the system:serviceaccount:openshift-monitoring:prometheus-k8s user.

@cdoern
Copy link
Contributor

cdoern commented Mar 7, 2024

/approve
/lgtm

Copy link
Contributor

openshift-ci bot commented Mar 7, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: cdoern, harche, rphillips

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:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Mar 7, 2024
@rphillips
Copy link
Contributor Author

/cherry-pick release-4.15

@openshift-cherrypick-robot

@rphillips: once the present PR merges, I will cherry-pick it on top of release-4.15 in a new PR and assign it to you.

In response to this:

/cherry-pick release-4.15

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD 53bbe70 and 2 for PR HEAD 757befb in total

Copy link
Contributor

openshift-ci bot commented Mar 7, 2024

@rphillips: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/okd-scos-e2e-aws-ovn 757befb link false /test okd-scos-e2e-aws-ovn

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@rphillips
Copy link
Contributor Author

/test e2e-gcp-op-single-node

@openshift-merge-bot openshift-merge-bot bot merged commit a073953 into openshift:master Mar 8, 2024
16 of 17 checks passed
@openshift-cherrypick-robot

@rphillips: #4175 failed to apply on top of branch "release-4.15":

Applying: OCPNODE-2098: add static pods for rbacproxy
Using index info to reconstruct a base tree...
M	pkg/operator/sync.go
Falling back to patching base and 3-way merge...
Auto-merging pkg/operator/sync.go
CONFLICT (content): Merge conflict in pkg/operator/sync.go
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0001 OCPNODE-2098: add static pods for rbacproxy
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".

In response to this:

/cherry-pick release-4.15

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-bot
Copy link
Contributor

[ART PR BUILD NOTIFIER]

This PR has been included in build ose-machine-config-operator-container-v4.16.0-202403081913.p0.ga073953.assembly.stream.el8 for distgit ose-machine-config-operator.
All builds following this will include this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants