-
Notifications
You must be signed in to change notification settings - Fork 104
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
Enable running the test-operator role multiple times #2412
base: main
Are you sure you want to change the base?
Enable running the test-operator role multiple times #2412
Conversation
Thanks for the PR! ❤️ |
Build failed (check pipeline). Post https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/de081b8b9823412e9114978d4382adbb ✔️ openstack-k8s-operators-content-provider SUCCESS in 2h 28m 42s |
4bc0d24
to
8ca52e7
Compare
8ca52e7
to
c33ee46
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @lpiwowar
Would it be better to use an randomly generated ID for each run regardless? This way a user would not need to manually specify a name for the second third run etc.
If the current implementation is best I have a suggestion to add a new section to the README for how to run the role multiple times, just with the details you mentioned in the commit message would be fine.
Hi @lewisdenny 👋, thank you for the review!
Adding the random suffix won't eliminate the need to specify a different name for each execution of the test-operator role. The name as specified in the README is used in
Ok, I'll update the README 👍 |
It was not possible to run the test-operator role multiple times without cleaning up all resources created by the first run, such as the logs pod created for the logs collection. This patch makes it possible to run the test operator role multiple times without cleaning up the resources (e.g., after the update in an update job). It is possible because: - test-operator-logs pod now has unique name for each job run - The variable cifmw_test_operator_*_name is now exposed. By specifying a unique name, we can guarantee no name collisions between the test-operator related resources (logs pods, instances of CRs) If you want to run test-operator role twice within a single job then make sure that for the second run you specify a value for the cifmw_test_operator_*_name. For example: cifmw_test_operator_tempest_name: "post-update-tempest-tests"
c33ee46
to
962fb5a
Compare
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Build failed (check pipeline). Post https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/80c65bcf1cf94b56aebc96c856f4837e ✔️ openstack-k8s-operators-content-provider SUCCESS in 2h 02m 49s |
Thank you for the detailed explanation mate. That along with the update README make it clear to me +1 from me. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
recheck |
Does this allow us to run test-operator twice or multiple times? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good to me
Build failed (check pipeline). Post https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/03edffcc7e6940cc90469725209d24e8 ✔️ openstack-k8s-operators-content-provider SUCCESS in 1h 49m 04s |
It was not possible to run the test-operator role multiple times without cleaning up all resources created by the first role run, such as the logs pod created for the logs collection.
This patch makes it possible to run the test operator role multiple times without cleaning up the resources (e.g., after the update in an update job). It is possible because:
If you want to run test-operator role twice within a single job then make sure that for the second run you specify a value for the cifmw_test_operator_*_name. For example:
cifmw_test_operator_tempest_name: "post-update-tempest-tests"