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

Bug 1885930: Gather ServiceAccounts stats from cluster namespaces #200

Merged

Conversation

martinkunc
Copy link
Contributor

The change is collecting numbers of service accounts from kubernetes default namespaces and openshift built-in namespaces (openshift*).
It would be used to detect that a particular SA exists in ns, specifically to target https://access.redhat.com/solutions/5221881 and find lib-bucket-provisioner from NS openshift-storage

@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 5, 2020
Copy link
Contributor

@rluders rluders left a comment

Choose a reason for hiding this comment

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

Didn't run the code yet, but I'll do it later, but looks good.

@tremes
Copy link
Contributor

tremes commented Oct 5, 2020

It looks good to me in general. Maybe we should increase interval: "30s" in config/local.yaml, because I was getting
Unable to read ServiceAccounts in namespace openshift-service-ca-operator error context deadline exceeded and

E1005 12:06:48.285236  145144 periodic.go:75] Unable to flush recorder: cancelled before all results could be written to disk
E1005 12:06:48.285265  145144 periodic.go:157] config failed after 15.002s with: context deadline exceeded

@martinkunc martinkunc force-pushed the gather-serviceaccounts branch from 1ab8790 to cb458c4 Compare October 5, 2020 11:31
@martinkunc martinkunc force-pushed the gather-serviceaccounts branch from cb458c4 to 7a0b3ac Compare October 5, 2020 11:34
@martinkunc
Copy link
Contributor Author

/retest

@tremes
Copy link
Contributor

tremes commented Oct 6, 2020

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Oct 6, 2020
@openshift-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: martinkunc, tremes

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-merge-robot openshift-merge-robot merged commit 6fc9194 into openshift:master Oct 6, 2020
@rluders
Copy link
Contributor

rluders commented Oct 6, 2020

/lgtm

@martinkunc martinkunc changed the title Gather ServiceAccounts stats from cluster namespaces Bug 1885930: Gather ServiceAccounts stats from cluster namespaces Oct 7, 2020
@openshift-ci-robot
Copy link
Contributor

@martinkunc: All pull requests linked via external trackers have merged:

Bugzilla bug 1885930 has been moved to the MODIFIED state.

In response to this:

Bug 1885930: Gather ServiceAccounts stats from cluster namespaces

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.

@martinkunc
Copy link
Contributor Author

/cherry-pick release-4.6

@openshift-cherrypick-robot

@martinkunc: new pull request created: #206

In response to this:

/cherry-pick release-4.6

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.

@martinkunc
Copy link
Contributor Author

/cherry-pick release-4.5

@openshift-cherrypick-robot

@martinkunc: #200 failed to apply on top of branch "release-4.5":

Applying: Gather ServiceAccounts stats from cluster namespaces
.git/rebase-apply/patch:47: new blank line at EOF.
+
warning: 1 line adds whitespace errors.
Using index info to reconstruct a base tree...
M	docs/gathered-data.md
M	pkg/controller/operator.go
M	pkg/gather/clusterconfig/clusterconfig.go
M	pkg/gather/clusterconfig/clusterconfig_test.go
Falling back to patching base and 3-way merge...
Auto-merging pkg/gather/clusterconfig/clusterconfig_test.go
CONFLICT (content): Merge conflict in pkg/gather/clusterconfig/clusterconfig_test.go
Auto-merging pkg/gather/clusterconfig/clusterconfig.go
CONFLICT (content): Merge conflict in pkg/gather/clusterconfig/clusterconfig.go
Auto-merging pkg/controller/operator.go
Auto-merging docs/gathered-data.md
CONFLICT (content): Merge conflict in docs/gathered-data.md
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0001 Gather ServiceAccounts stats from cluster namespaces
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.5

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.

@martinkunc
Copy link
Contributor Author

/cherry-pick release-4.4

@openshift-cherrypick-robot

@martinkunc: #200 failed to apply on top of branch "release-4.4":

Applying: Gather ServiceAccounts stats from cluster namespaces
.git/rebase-apply/patch:47: new blank line at EOF.
+
warning: 1 line adds whitespace errors.
Using index info to reconstruct a base tree...
M	config/local.yaml
M	docs/gathered-data.md
M	pkg/controller/operator.go
M	pkg/gather/clusterconfig/clusterconfig.go
M	pkg/gather/clusterconfig/clusterconfig_test.go
Falling back to patching base and 3-way merge...
Auto-merging pkg/gather/clusterconfig/clusterconfig_test.go
CONFLICT (content): Merge conflict in pkg/gather/clusterconfig/clusterconfig_test.go
Auto-merging pkg/gather/clusterconfig/clusterconfig.go
CONFLICT (content): Merge conflict in pkg/gather/clusterconfig/clusterconfig.go
Auto-merging pkg/controller/operator.go
Auto-merging docs/gathered-data.md
CONFLICT (content): Merge conflict in docs/gathered-data.md
Auto-merging config/local.yaml
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0001 Gather ServiceAccounts stats from cluster namespaces
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.4

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.

martinkunc pushed a commit to martinkunc/insights-operator that referenced this pull request Oct 13, 2020
Gather ServiceAccounts stats from cluster namespaces
Fix buid with missing library by using -mod=vendor
martinkunc pushed a commit to martinkunc/insights-operator that referenced this pull request Oct 14, 2020
Gather ServiceAccounts stats from cluster namespaces
Fix buid with missing library by using -mod=vendor

 Please enter the commit message for your changes. Lines starting
martinkunc added a commit to martinkunc/insights-operator that referenced this pull request Oct 14, 2020
Gather ServiceAccounts stats from cluster namespaces
Fix buid with missing library by using -mod=vendor
martinkunc pushed a commit to martinkunc/insights-operator that referenced this pull request Oct 15, 2020
Gather ServiceAccounts stats from cluster namespaces
Fix buid with missing library by using -mod=vendor

 Please enter the commit message for your changes. Lines starting
rluders pushed a commit to rluders/insights-operator that referenced this pull request Nov 2, 2020
Gather ServiceAccounts stats from cluster namespaces
Fix buid with missing library by using -mod=vendor

 Please enter the commit message for your changes. Lines starting
rluders pushed a commit to rluders/insights-operator that referenced this pull request Nov 2, 2020
Gather ServiceAccounts stats from cluster namespaces
Fix buid with missing library by using -mod=vendor
rluders pushed a commit to rluders/insights-operator that referenced this pull request Nov 2, 2020
Gather ServiceAccounts stats from cluster namespaces
Fix buid with missing library by using -mod=vendor
openshift-merge-robot added a commit that referenced this pull request Feb 26, 2021
* [4.5] Adds PodDisruptionBudgets gather.

* Merge pull request #200 from martinkunc/gather-serviceaccounts
Gather ServiceAccounts stats from cluster namespaces
Fix buid with missing library by using -mod=vendor

 Please enter the commit message for your changes. Lines starting

* Merge pull request #200 from martinkunc/gather-serviceaccounts
Gather ServiceAccounts stats from cluster namespaces
Fix buid with missing library by using -mod=vendor

* Fix some issues by rebase

* Removing some variables from makefile

Co-authored-by: Marcell Sevcsik <msevcsik@redhat.com>
Co-authored-by: OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>
Co-authored-by: Martin Kunc <5441732+martinkunc@users.noreply.github.com>
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. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants