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

openstack: add simple test for the openstack-populator #668

Merged
merged 3 commits into from
Dec 24, 2023

Conversation

bennyz
Copy link
Member

@bennyz bennyz commented Dec 3, 2023

  • This PR also changes the populator controller and ovirt-populator to use envFrom instead of a file to pass the secret.

This will eventually go into the CDI controller PR, but is also useful here for now

@bennyz bennyz force-pushed the openstack-test branch 2 times, most recently from b7e57be to 2ab9534 Compare December 4, 2023 08:25
Copy link
Member

@ahadas ahadas left a comment

Choose a reason for hiding this comment

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

nice! minor comment inside
ah and SonarCloud has a point in the code smell it reports..

cmd/ovirt-populator/ovirt-populator.go Outdated Show resolved Hide resolved
@ahadas
Copy link
Member

ahadas commented Dec 4, 2023

ah and SonarCloud has a point in the code smell it reports..

@bennyz so what about that tiny part?

Use envFrom to pass secrets to the populator controller. This simplifies
the code, and makes the openstack test introduced in the patch easier to
implement.

Signed-off-by: Benny Zlotnik <bzlotnik@redhat.com>
It uses a fake openstack server, but a real file is created

Signed-off-by: Benny Zlotnik <bzlotnik@redhat.com>
@bennyz bennyz force-pushed the openstack-test branch 4 times, most recently from 7a96fc8 to b7dbf0e Compare December 19, 2023 11:01
@bennyz bennyz marked this pull request as ready for review December 19, 2023 11:01
Copy link
Member

@liranr23 liranr23 left a comment

Choose a reason for hiding this comment

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

what's the exact benefit? will you see secret in the env of the pod?

.github/workflows/go-test.yaml Outdated Show resolved Hide resolved
Signed-off-by: Benny Zlotnik <bzlotnik@redhat.com>
Copy link

sonarcloud bot commented Dec 19, 2023

Quality Gate Passed Quality Gate passed

Kudos, no new issues were introduced!

0 New issues
0 Security Hotspots
No data about Coverage
5.1% Duplication on New Code

See analysis details on SonarCloud

@ahadas
Copy link
Member

ahadas commented Dec 24, 2023

what's the exact benefit? will you see secret in the env of the pod?

yeah, it's a cleaner way to get data from a secret in a pod

@ahadas ahadas merged commit 7f78117 into kubev2v:main Dec 24, 2023
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants