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

[V2] CLI host flag validation #1741

Open
lynnemorrison opened this issue Oct 22, 2024 · 3 comments
Open

[V2] CLI host flag validation #1741

lynnemorrison opened this issue Oct 22, 2024 · 3 comments

Comments

@lynnemorrison
Copy link
Collaborator

lynnemorrison commented Oct 22, 2024

We need to add a validator to the host flag in the CLI. For both kube and nonkube CLI we need to validate the host flag being passed. We need to understand what values are valid for the host flag.

@lynnemorrison
Copy link
Collaborator Author

@grs and @ssorj can you help me with what values are allowed in this field.

@lynnemorrison lynnemorrison changed the title [V2] CLI host validation [V2] CLI host flag validation Oct 22, 2024
@nluaces
Copy link
Member

nluaces commented Oct 23, 2024

My suggestion is to:

  • Check if it is an IP
  • If not, check if the length is equal or less than a number and that it only contains allowed characters: alphabetic characters (A-Z), numeric characters (0-9), the minus sign (-), and the period (.)

@grs
Copy link
Member

grs commented Dec 13, 2024

I'm not sure I would add any constraints at this point. However I would agree with @nluaces above if we do.

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

No branches or pull requests

3 participants