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

Added controller for running ansible playbooks #97

Merged
merged 2 commits into from
Jul 3, 2024

Conversation

eshulman2
Copy link

@eshulman2 eshulman2 commented May 21, 2024

This addition should be flexible enough to run
ansible playbooks for testing popuses.
it is dependent on this patch
openstack-k8s-operators/tcib#182

Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://review.rdoproject.org/zuul/buildset/aad46f8a405f443aa6272c7f768254d4

openstack-k8s-operators-content-provider FAILURE in 8m 04s
⚠️ podified-multinode-edpm-deployment-crc-test-operator SKIPPED Skipped due to failed job openstack-k8s-operators-content-provider

@lpiwowar
Copy link
Collaborator

lpiwowar commented May 21, 2024

Hi @eshulman2, thanks for the PR! This is going to be helpful once we merge this!

I will do a deeper review a little bit later but in the meantime there are some failures that need to be fixed [1]:

 # github.com/openstack-k8s-operators/test-operator/controllers
2024-05-21 07:39:12.311503 | controller |     controllers/trex_performance_controller.go:21:2: "fmt" imported and not used
2024-05-21 07:39:12.311509 | controller |     controllers/trex_performance_controller.go:168:3: not enough arguments in call to r.EnsureLogsPVCExists
2024-05-21 07:39:12.311516 | controller |             have (context.Context, *"github.com/openstack-k8s-operators/test-operator/api/v1beta1".TrexPerformance, *helper.Helper, map[string]string, string)
2024-05-21 07:39:12.311522 | controller |             want (context.Context, client.Object, *helper.Helper, map[string]string, string, bool)
2024-05-21 07:39:12.311533 | controller |     controllers/trex_performance_controller.go:273:24: instance.Spec.TrexPerformanceSpec undefined (type "github.com/openstack-k8s-operators/test-operator/api/v1beta1".TrexPerformanceSpec has no field or method TrexPerformanceSpec)
2024-05-21 07:39:12.311542 | controller |     controllers/trex_performance_controller.go:276:51: instance.Spec.Workflow[workflowStepNum].TrexPerformanceSpec undefined (type "github.com/openstack-k8s-operators/test-operator/api/v1beta1".TrexPerformanceWorkflowSpec has no field or method TrexPerformanceSpec)
2024-05-21 07:39:12.311550 | controller |     controllers/trex_performance_controller.go:282:58: wtRun.Serial undefined (type "github.com/openstack-k8s-operators/test-operator/api/v1beta1".TrexPerformanceWorkflowSpec has no field or method Serial)
2024-05-21 07:39:12.311557 | controller |     controllers/trex_performance_controller.go:290:2: undefined: value
2024-05-21 07:39:12.311563 | controller |     controllers/trex_performance_controller.go:291:9: undefined: value
2024-05-21 07:39:12.311570 | controller |     controllers/trex_performance_controller.go:292:40: undefined: value
2024-05-21 07:39:12.311576 | controller |     controllers/trex_performance_controller.go:297:6: mergeWithWorkflow redeclared in this block
2024-05-21 07:39:12.311583 | controller |             controllers/tempest_controller.go:471:6: other declaration of mergeWithWorkflow
2024-05-21 07:39:12.311589 | controller |     controllers/trex_performance_controller.go:317:62: undefined: tempest
2024-05-21 07:39:12.311604 | controller |     controllers/trex_performance_controller.go:21:2: too many errors

I recommend at least running the test-operator with make install run before pushing the change. It looks like copy paste issues from the tempest part that should be easy to fix and some undefined variables.

[1] https://logserver.rdoproject.org/97/97/77d2a159a959cc584d3f36d7305e3202c1e412f0/github-check/openstack-k8s-operators-content-provider/d166321/job-output.txt

Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://review.rdoproject.org/zuul/buildset/b44f1c923d474454befe1cc2fc0c47f3

openstack-k8s-operators-content-provider FAILURE in 8m 17s
⚠️ podified-multinode-edpm-deployment-crc-test-operator SKIPPED Skipped due to failed job openstack-k8s-operators-content-provider

Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://review.rdoproject.org/zuul/buildset/a4bc558a6b474eb99f0be5b432535654

openstack-k8s-operators-content-provider FAILURE in 8m 35s
⚠️ podified-multinode-edpm-deployment-crc-test-operator SKIPPED Skipped due to failed job openstack-k8s-operators-content-provider

Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://review.rdoproject.org/zuul/buildset/2fcf0b95929d438e844430ca54b503b9

openstack-k8s-operators-content-provider FAILURE in 8m 52s
⚠️ podified-multinode-edpm-deployment-crc-test-operator SKIPPED Skipped due to failed job openstack-k8s-operators-content-provider

@eshulman2
Copy link
Author

Hi @eshulman2, thanks for the PR! This is going to be helpful once we merge this!

I will do a deeper review a little bit later but in the meantime there are some failures that need to be fixed [1]:

 # github.com/openstack-k8s-operators/test-operator/controllers
2024-05-21 07:39:12.311503 | controller |     controllers/trex_performance_controller.go:21:2: "fmt" imported and not used
2024-05-21 07:39:12.311509 | controller |     controllers/trex_performance_controller.go:168:3: not enough arguments in call to r.EnsureLogsPVCExists
2024-05-21 07:39:12.311516 | controller |             have (context.Context, *"github.com/openstack-k8s-operators/test-operator/api/v1beta1".TrexPerformance, *helper.Helper, map[string]string, string)
2024-05-21 07:39:12.311522 | controller |             want (context.Context, client.Object, *helper.Helper, map[string]string, string, bool)
2024-05-21 07:39:12.311533 | controller |     controllers/trex_performance_controller.go:273:24: instance.Spec.TrexPerformanceSpec undefined (type "github.com/openstack-k8s-operators/test-operator/api/v1beta1".TrexPerformanceSpec has no field or method TrexPerformanceSpec)
2024-05-21 07:39:12.311542 | controller |     controllers/trex_performance_controller.go:276:51: instance.Spec.Workflow[workflowStepNum].TrexPerformanceSpec undefined (type "github.com/openstack-k8s-operators/test-operator/api/v1beta1".TrexPerformanceWorkflowSpec has no field or method TrexPerformanceSpec)
2024-05-21 07:39:12.311550 | controller |     controllers/trex_performance_controller.go:282:58: wtRun.Serial undefined (type "github.com/openstack-k8s-operators/test-operator/api/v1beta1".TrexPerformanceWorkflowSpec has no field or method Serial)
2024-05-21 07:39:12.311557 | controller |     controllers/trex_performance_controller.go:290:2: undefined: value
2024-05-21 07:39:12.311563 | controller |     controllers/trex_performance_controller.go:291:9: undefined: value
2024-05-21 07:39:12.311570 | controller |     controllers/trex_performance_controller.go:292:40: undefined: value
2024-05-21 07:39:12.311576 | controller |     controllers/trex_performance_controller.go:297:6: mergeWithWorkflow redeclared in this block
2024-05-21 07:39:12.311583 | controller |             controllers/tempest_controller.go:471:6: other declaration of mergeWithWorkflow
2024-05-21 07:39:12.311589 | controller |     controllers/trex_performance_controller.go:317:62: undefined: tempest
2024-05-21 07:39:12.311604 | controller |     controllers/trex_performance_controller.go:21:2: too many errors

I recommend at least running the test-operator with make install run before pushing the change. It looks like copy paste issues from the tempest part that should be easy to fix and some undefined variables.

[1] https://logserver.rdoproject.org/97/97/77d2a159a959cc584d3f36d7305e3202c1e412f0/github-check/openstack-k8s-operators-content-provider/d166321/job-output.txt

Sorry for the awful code from before was just copying around and pushing as an initial stage, should be better now.

Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://review.rdoproject.org/zuul/buildset/8490d7c928bb479088ee00164e62e445

openstack-k8s-operators-content-provider FAILURE in 8m 25s
⚠️ podified-multinode-edpm-deployment-crc-test-operator SKIPPED Skipped due to failed job openstack-k8s-operators-content-provider

@eshulman2 eshulman2 force-pushed the NFV-performance branch 2 times, most recently from 5dd109a to 4e37f5b Compare May 22, 2024 16:07
Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://review.rdoproject.org/zuul/buildset/2b7644fb98304844a52f378e20de8cef

openstack-k8s-operators-content-provider FAILURE in 8m 30s
⚠️ podified-multinode-edpm-deployment-crc-test-operator SKIPPED Skipped due to failed job openstack-k8s-operators-content-provider

main.go Outdated Show resolved Hide resolved
pkg/trexperf/volumes.go Outdated Show resolved Hide resolved
pkg/trexperf/volumes.go Outdated Show resolved Hide resolved
pkg/trexperf/volumes.go Outdated Show resolved Hide resolved
pkg/trexperf/volumes.go Outdated Show resolved Hide resolved
@lpiwowar lpiwowar marked this pull request as draft May 27, 2024 11:37
Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://review.rdoproject.org/zuul/buildset/39102cf33a5c451c9cb5db3c1dffd79c

✔️ openstack-k8s-operators-content-provider SUCCESS in 3h 38m 37s
podified-multinode-edpm-deployment-crc-test-operator TIMED_OUT in 3h 11m 44s

Copy link

Merge Failed.

This change or one of its cross-repo dependencies was unable to be automatically merged with the current state of its repository. Please rebase the change and upload a new patchset.
Warning:
Error merging github.com/openstack-k8s-operators/test-operator for 97,2878c5df14e428813bdabba3405f9af7b86921bc

Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://review.rdoproject.org/zuul/buildset/d29eadb208d441388b0671b25c1e907f

✔️ openstack-k8s-operators-content-provider SUCCESS in 3h 18m 01s
podified-multinode-edpm-deployment-crc-test-operator TIMED_OUT in 3h 09m 12s

@eshulman2 eshulman2 force-pushed the NFV-performance branch 2 times, most recently from 45b958a to 3e04b6c Compare July 1, 2024 12:04
@eshulman2 eshulman2 changed the title Added controller for running trex performance Added controller for running ansible playbooks Jul 1, 2024
Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://review.rdoproject.org/zuul/buildset/77ea3d1e8bf9469e8c7180c65aca70e0

✔️ openstack-k8s-operators-content-provider SUCCESS in 3h 17m 28s
podified-multinode-edpm-deployment-crc-test-operator TIMED_OUT in 3h 09m 02s

Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://review.rdoproject.org/zuul/buildset/028f82349efd4db6859f6ed9290ede33

✔️ openstack-k8s-operators-content-provider SUCCESS in 3h 19m 21s
podified-multinode-edpm-deployment-crc-test-operator TIMED_OUT in 3h 10m 00s

Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://review.rdoproject.org/zuul/buildset/5465794a9b27491daef6dc19682d7ff5

✔️ openstack-k8s-operators-content-provider SUCCESS in 3h 20m 21s
podified-multinode-edpm-deployment-crc-test-operator TIMED_OUT in 3h 09m 18s

apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
name: ansibleTest.test.openstack.org
Copy link
Collaborator

Choose a reason for hiding this comment

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

@eshulman2 I think we have to go through the occurrences of the ansibleTest in the PR. And think whether it should be capitalized or not. As an example you can take a look at HorizonTest CR. You can see that for example here [1] the name for HorionTests CR is not capitalized.

Also, checking whether the test-operator works from locally build test-operator-index would be in this case a good idea I think [2] (question #7).

[1]

name: horizontests.test.openstack.org

[2] https://openstack-k8s-operators.github.io/test-operator/FAQ.html

lpiwowar added a commit to lpiwowar/ci-framework that referenced this pull request Jul 3, 2024
In this PR [1] we introduce AnsibleTest CR. This patch extends
the test-operator so that it can be used to execute tests using the
newly introduced CR.

[1] openstack-k8s-operators/test-operator#97
@eshulman2 eshulman2 force-pushed the NFV-performance branch 2 times, most recently from 5a3b5ce to 5704597 Compare July 3, 2024 12:54
This addition should be flexible enough to run
ansible playbooks for testing popuses.
it is dependent on this patch
openstack-k8s-operators/tcib#182
@lpiwowar lpiwowar self-requested a review July 3, 2024 17:46
Copy link
Collaborator

@lpiwowar lpiwowar left a comment

Choose a reason for hiding this comment

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

LGTM! 👍
I think this is a solid foundation for the AnsibleTest CR. We can always address any minor potential issues down the road.

@lpiwowar lpiwowar merged commit 2173e83 into openstack-k8s-operators:main Jul 3, 2024
3 checks passed
lpiwowar added a commit to lpiwowar/ci-framework that referenced this pull request Jul 3, 2024
In this PR [1] we introduce AnsibleTest CR. This patch extends
the test-operator so that it can be used to execute tests using the
newly introduced CR.

[1] openstack-k8s-operators/test-operator#97
lpiwowar added a commit to lpiwowar/ci-framework that referenced this pull request Jul 3, 2024
In this PR [1] we introduce AnsibleTest CR. This patch extends
the test-operator so that it can be used to execute tests using the
newly introduced CR.

[1] openstack-k8s-operators/test-operator#97
lpiwowar added a commit to lpiwowar/ci-framework that referenced this pull request Jul 4, 2024
In this PR [1] we introduce AnsibleTest CR. This patch extends
the test-operator so that it can be used to execute tests using the
newly introduced CR.

[1] openstack-k8s-operators/test-operator#97
lpiwowar added a commit to lpiwowar/ci-framework that referenced this pull request Jul 4, 2024
In this PR [1] we introduce AnsibleTest CR. This patch extends
the test-operator so that it can be used to execute tests using the
newly introduced CR.

[1] openstack-k8s-operators/test-operator#97
lpiwowar added a commit to lpiwowar/ci-framework that referenced this pull request Jul 4, 2024
In this PR [1] we introduce AnsibleTest CR. This patch extends
the test-operator so that it can be used to execute tests using the
newly introduced CR.

[1] openstack-k8s-operators/test-operator#97
openshift-merge-bot bot pushed a commit to openstack-k8s-operators/ci-framework that referenced this pull request Jul 8, 2024
In this PR [1] we introduce AnsibleTest CR. This patch extends
the test-operator so that it can be used to execute tests using the
newly introduced CR.

[1] openstack-k8s-operators/test-operator#97
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants