-
Notifications
You must be signed in to change notification settings - Fork 239
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
bundle validation: check for bundle preset mismatch during setup #4343
Conversation
[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 |
Also, I think |
7c9961b
to
1921db4
Compare
1921db4
to
497e0d9
Compare
i think this got changed, now they don't contain |
Ah ok, I was tricked by |
497e0d9
to
3fa3f31
Compare
Thanks for the suggestion @cfergeau, I modified your regex a bit and it worked really well. |
3fa3f31
to
353fc52
Compare
@redbeam: The following tests failed, say
Full PR test history. Your PR dashboard. 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-sigs/prow repository. I understand the commands that are listed here. |
Recently on crc side[0] we have enabled the regex to capture bundle info and as part of this regex we are capturing the custom bundle which is random generated number like `crc_okd_vfkit_4.16.7_amd64_2342465234654.crcbundle` but for bundles generated by the pr have suffix `.pr<pr_number>` which means again adjust the regex. We can still identify the bundle with `_<pr_number>` and this way we don't need to update the regex. - crc-org/crc#4343
Recently on crc side[0] we have enabled the regex to capture bundle info and as part of this regex we are capturing the custom bundle which is random generated number like `crc_okd_vfkit_4.16.7_amd64_2342465234654.crcbundle` but for bundles generated by the pr have suffix `.pr<pr_number>` which means again adjust the regex. We can still identify the bundle with `_<pr_number>` and this way we don't need to update the regex. - crc-org/crc#4343
Recently on crc side[0] we have enabled the regex to capture bundle info and as part of this regex we are capturing the custom bundle which is random generated number like `crc_okd_vfkit_4.16.7_amd64_2342465234654.crcbundle` but for bundles generated by the pr have suffix `.pr<pr_number>` which means again adjust the regex. We can still identify the bundle with `_<pr_number>` and this way we don't need to update the regex. - crc-org/crc#4343
Recently on crc side[0] we have enabled the regex to capture bundle info and as part of this regex we are capturing the custom bundle which is random generated number like `crc_okd_vfkit_4.16.7_amd64_2342465234654.crcbundle` but for bundles generated by the pr have suffix `.pr<pr_number>` which means again adjust the regex. We can still identify the bundle with `_<pr_number>` and this way we don't need to update the regex. - crc-org/crc#4343
Recently on crc side[0] we have enabled the regex to capture bundle info and as part of this regex we are capturing the custom bundle which is random generated number like `crc_okd_vfkit_4.16.7_amd64_2342465234654.crcbundle` but for bundles generated by the pr have suffix `.pr<pr_number>` which means again adjust the regex. We can still identify the bundle with `_<pr_number>` and this way we don't need to update the regex. - crc-org/crc#4343
Recently on crc side[0] we have enabled the regex to capture bundle info and as part of this regex we are capturing the custom bundle which is random generated number like `crc_okd_vfkit_4.16.7_amd64_2342465234654.crcbundle` but for bundles generated by the pr have suffix `.pr<pr_number>` which means again adjust the regex. We can still identify the bundle with `_<pr_number>` and this way we don't need to update the regex. - crc-org/crc#4343
Recently on crc side[0] we have enabled the regex to capture bundle info and as part of this regex we are capturing the custom bundle which is random generated number like `crc_okd_vfkit_4.16.7_amd64_2342465234654.crcbundle` but for bundles generated by the pr have suffix `.pr<pr_number>` which means again adjust the regex. We can still identify the bundle with `_<pr_number>` and this way we don't need to update the regex. - crc-org/crc#4343
Recently on crc side[0] we have enabled the regex to capture bundle info and as part of this regex we are capturing the custom bundle which is random generated number like `crc_okd_vfkit_4.16.7_amd64_2342465234654.crcbundle` but for bundles generated by the pr have suffix `.pr<pr_number>` which means again adjust the regex. We can still identify the bundle with `_<pr_number>` and this way we don't need to update the regex. - crc-org/crc#4343
Recently on crc side[0] we have enabled the regex to capture bundle info and as part of this regex we are capturing the custom bundle which is random generated number like `crc_okd_vfkit_4.16.7_amd64_2342465234654.crcbundle` but for bundles generated by the pr have suffix `.pr<pr_number>` which means again adjust the regex. We can still identify the bundle with `_<pr_number>` and this way we don't need to update the regex. - crc-org/crc#4343
Fixes: Issue #3615
Added a check for bundle type mismatch with preset in function
ValidateBundle
.crc/pkg/crc/validation/validation.go
Lines 91 to 107 in 7b04ce5
The check is performed before checking for custom bundle (and potentially displaying a warning).
Function
BundleMismatchWithPreset
was moved frommachine/start.go
tovalidation/validation.go
and is used during start as well.Testing
crc config set preset openshift
crc setup --bundle <path_to_bundle>
Output:
FATA Preset openshift is used but bundle is provided for microshift preset