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

Add UEFI HTTP Boot provisioning test #12908

Merged
merged 1 commit into from
Nov 20, 2023

Conversation

shubhamsg199
Copy link
Contributor

Adding UEFI HTTP Boot provisioning test. The test will be skipped till the BZ#2242925 is fixed

@shubhamsg199 shubhamsg199 added CherryPick PR needs CherryPick to previous branches 6.12.z Introduced in or relating directly to Satellite 6.12 AutoMerge_Cherry_Picked The cherrypicked PRs of master PR would be automerged if all checks passing 6.13.z Introduced in or relating directly to Satellite 6.13 6.14.z Introduced in or relating directly to Satellite 6.14 labels Oct 13, 2023
@shubhamsg199 shubhamsg199 self-assigned this Oct 13, 2023
@shubhamsg199 shubhamsg199 requested review from a team as code owners October 13, 2023 14:01
Copy link
Member

@jyejare jyejare left a comment

Choose a reason for hiding this comment

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

ACK, looks good!

Could we please run PRT if possible for provisioning!

Copy link
Collaborator

@Gauravtalreja1 Gauravtalreja1 left a comment

Choose a reason for hiding this comment

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

Ack, great job @shubhamsg199

@jyejare PRT will skip this tests as he's using pytest.mark.skip_if_open("BZ:2242925")

Copy link
Member

@rplevka rplevka left a comment

Choose a reason for hiding this comment

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

I see no assertions that would test that the host is indeed being provisioned by HTTPBoot.
Satellite used to deploy the pxelinux and grub config files along the others no matter what kind of OS bootloader you selected. So I am wondering whether the host is indeed using the HTTPBoot here and not just falling back to any other method.
This test does not do any kind of introspection into the boot and installer procedures at all and simply blindly waits till the host build status is being flipped in satellite.
I'd personally expect more assertions especially in this area as there are several points where the provisioning might go wrong (invalid provisoning token being passed, proxy not reachable, rendered template being wrong,...).
Having a failed test of this kind, not knowing what happened sounds non-optimal to me.

I'd suggest to add some checkpoints, like listening to incoming HTTP requests to the HTTP proxy to ensure, that a correct request indeed arrived and that the proxy correctly responded to it.
We could as well issue the call to proxy manually and see if we get the properly rendered template with the given provisioning token (at least just log it or save it as an artifact for the eventual TFA).

Thoughts?

@shubhamsg199
Copy link
Contributor Author

shubhamsg199 commented Oct 20, 2023

I see no assertions that would test that the host is indeed being provisioned by HTTPBoot. Satellite used to deploy the pxelinux and grub config files along the others no matter what kind of OS bootloader you selected. So I am wondering whether the host is indeed using the HTTPBoot here and not just falling back to any other method. This test does not do any kind of introspection into the boot and installer procedures at all and simply blindly waits till the host build status is being flipped in satellite. I'd personally expect more assertions especially in this area as there are several points where the provisioning might go wrong (invalid provisoning token being passed, proxy not reachable, rendered template being wrong,...). Having a failed test of this kind, not knowing what happened sounds non-optimal to me.

I'd suggest to add some checkpoints, like listening to incoming HTTP requests to the HTTP proxy to ensure, that a correct request indeed arrived and that the proxy correctly responded to it. We could as well issue the call to proxy manually and see if we get the properly rendered template with the given provisioning token (at least just log it or save it as an artifact for the eventual TFA).

Thoughts?

If we select Grub2 UEFI HTTP as pxe loader, the booting always starts with PXE over ipv4 then ipv6 and then over HTTP ipv4 and ipv6. However, PXE over ipv4 tries to download the grubx64.efi file but it fails, so I guess the Bootloader here matters.
I'll try to implement some functions maybe to read logs to verify the HTTP requests(similar to what we have in discovery tests)

@shubhamsg199 shubhamsg199 force-pushed the httpboot_provisioning branch from 598ab1a to 8bf7d4f Compare November 6, 2023 08:11
Copy link
Member

@rplevka rplevka left a comment

Choose a reason for hiding this comment

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

thanks for implementing it.
there are few more log patterns you might test down the road, e.g. request for the ks file, etc. but i am not going to block the PR on this.

thank you

@rplevka rplevka merged commit cd2d2b0 into SatelliteQE:master Nov 20, 2023
5 checks passed
github-actions bot pushed a commit that referenced this pull request Nov 20, 2023
Signed-off-by: Shubham Ganar <[email protected]>
(cherry picked from commit cd2d2b0)
github-actions bot pushed a commit that referenced this pull request Nov 20, 2023
Signed-off-by: Shubham Ganar <[email protected]>
(cherry picked from commit cd2d2b0)
Gauravtalreja1 pushed a commit that referenced this pull request Nov 20, 2023
Add UEFI HTTP Boot provisioning test (#12908)

Signed-off-by: Shubham Ganar <[email protected]>
(cherry picked from commit cd2d2b0)

Co-authored-by: Shubham Ganar <[email protected]>
Gauravtalreja1 pushed a commit that referenced this pull request Nov 22, 2023
Add UEFI HTTP Boot provisioning test (#12908)

Signed-off-by: Shubham Ganar <[email protected]>
(cherry picked from commit cd2d2b0)

Co-authored-by: Shubham Ganar <[email protected]>
shweta83 pushed a commit to shweta83/robottelo that referenced this pull request Apr 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.12.z Introduced in or relating directly to Satellite 6.12 6.13.z Introduced in or relating directly to Satellite 6.13 6.14.z Introduced in or relating directly to Satellite 6.14 AutoMerge_Cherry_Picked The cherrypicked PRs of master PR would be automerged if all checks passing CherryPick PR needs CherryPick to previous branches
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants