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

accept amitype in kubetest2 managed nodegroup creation #438

Merged
merged 1 commit into from
Apr 10, 2024

Conversation

ndbaker1
Copy link
Contributor

Issue #, if available:

Description of changes:

add a flag to pass ami-type to the nodegroup creation for kubetest2 deployer

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@cartermckinnon
Copy link
Member

cartermckinnon commented Apr 10, 2024

I think we should add validation that a --ami-type and --ami aren't used together, the latter only has effect if --unmanaged-nodes is used.

@ndbaker1 ndbaker1 force-pushed the amitype branch 2 times, most recently from 80e28c7 to 605d7e4 Compare April 10, 2024 21:29
Comment on lines 263 to 264
if d.AMIType != "" && d.AMI != "" {
return fmt.Errorf("Cannot accept mutually exclusive flags --ami-type and --ami because it implies conflicting deployment modes")
Copy link
Contributor Author

Choose a reason for hiding this comment

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

need some suggestion on this message/condition. we don't validate you can't provide the --ami flag if you're not using unmanaged nodes, so not sure whether enforcing this is useful in practice @cartermckinnon

Copy link
Member

Choose a reason for hiding this comment

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

I think it'd be nice to validate that too :) but it's fine to just say "these two flags are mutually exclusive" in the error message, the flag docs can explain when/how a flag is used

Copy link
Contributor Author

@ndbaker1 ndbaker1 Apr 10, 2024

Choose a reason for hiding this comment

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

validating each on their own according to --unmanaged-nodes handles the mutual exclusion and i think is clearer. small update with this

@cartermckinnon cartermckinnon merged commit 7e98bc3 into aws:main Apr 10, 2024
2 checks passed
@ndbaker1 ndbaker1 deleted the amitype branch April 10, 2024 23:03
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