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 guidance on infrastructure resource names to provider implementation guides #7030

Open
randomvariable opened this issue Aug 5, 2022 · 10 comments
Labels
help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. kind/documentation Categorizes issue or PR as related to documentation. priority/backlog Higher priority than priority/awaiting-more-evidence. triage/accepted Indicates an issue or PR is ready to be actively worked on.

Comments

@randomvariable
Copy link
Member

randomvariable commented Aug 5, 2022

User Story

As a user, on some infrastructures when I go to deploy a cluster with names like the following, I experience some form of breakage:

Example names

  • default/longnamemorethansixtythreecharacterslong
  • default/names.using.dots.in.them
  • same cluster name, but in a different namespace ( default/cluster1 businessunit1/cluster1)

Example forms of breakage

  • The cluster infrastructure doesn't come up
  • The VM doesn't come up
  • The VM does come up but doesn't complete bootstrap, and there's complaints from cloud-init about the hostname.

Detailed Description

Provider contracts in https://github.com/kubernetes-sigs/cluster-api/blob/main/docs/book/src/developer/providers/machine-infrastructure.md and https://github.com/kubernetes-sigs/cluster-api/blob/main/docs/book/src/developer/providers/cluster-infrastructure.md should include guidance on how to implement the provider to accept all valid Kubernetes resource names, including techniques like conditional hashing (kubernetes-sigs/cluster-api-provider-aws#1290).

And then after we do that, we should probably circulate this amongst provider implementers so they can check they're not affected, and maybe add appropriate E2Es according to the constraints of their infrastructure provider.

Anything else you would like to add:

A bunch of related issues:

[Miscellaneous information that will assist in solving the issue.]

/kind docs

@k8s-ci-robot
Copy link
Contributor

@randomvariable: The label(s) kind/docs cannot be applied, because the repository doesn't have them.

In response to this:

User Story

As a user, on some infrastructures when I go to deploy a cluster with names like the following, I experience some form of breakage:

Example names

  • longnamemorethansixtythreecharacterslong
  • names.using.dots.in.them
  • same cluster name, but in a different namespace

Example forms of breakage

  • The cluster infrastructure doesn't come up
  • The VM doesn't come up
  • The VM does come up but doesn't complete bootstrap, and there's complaints from cloud-init about the hostname.

Detailed Description

Provider contracts in https://github.com/kubernetes-sigs/cluster-api/blob/main/docs/book/src/developer/providers/machine-infrastructure.md and https://github.com/kubernetes-sigs/cluster-api/blob/main/docs/book/src/developer/providers/cluster-infrastructure.md should include guidance on how to implement the provider to accept all valid Kubernetes resource names, including techniques like conditional hashing (kubernetes-sigs/cluster-api-provider-aws#1290).

And then after we do that, we should probably circulate this amongst provider implementers so they can check they're not affected, and maybe add appropriate E2Es according to the constraints of their infrastructure provider.

Anything else you would like to add:

A bunch of related issues:

[Miscellaneous information that will assist in solving the issue.]

/kind docs

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/test-infra repository.

@k8s-ci-robot k8s-ci-robot added the needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. label Aug 5, 2022
@randomvariable
Copy link
Member Author

Should add I'm happy to make the docs change.

Does anyone have any other examples of stuff that should be documented?

@randomvariable
Copy link
Member Author

/assign

@fabriziopandini
Copy link
Member

/kind documentation
/triage accepted

@k8s-ci-robot k8s-ci-robot added kind/documentation Categorizes issue or PR as related to documentation. triage/accepted Indicates an issue or PR is ready to be actively worked on. and removed needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Aug 5, 2022
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue or PR as fresh with /remove-lifecycle stale
  • Mark this issue or PR as rotten with /lifecycle rotten
  • Close this issue or PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Nov 3, 2022
@fabriziopandini
Copy link
Member

in CAPI we can give some general guidelines, but documentation for each infrastructure should be implemented in each provider.

if we want to fix this properly, one possible approach is to implement additional validation webhooks for CAPI resources in providers, but this seems out of scope of the current request so eventually this + follow up discussions should be moved to a separated issue

/lifecycle frozen
/unassign @randomvariable
/help

@k8s-ci-robot
Copy link
Contributor

@fabriziopandini:
This request has been marked as needing help from a contributor.

Guidelines

Please ensure that the issue body includes answers to the following questions:

  • Why are we solving this issue?
  • To address this issue, are there any code changes? If there are code changes, what needs to be done in the code and what places can the assignee treat as reference points?
  • Does this issue have zero to low barrier of entry?
  • How can the assignee reach out to you for help?

For more details on the requirements of such an issue, please see here and ensure that they are met.

If this request no longer meets these requirements, the label can be removed
by commenting with the /remove-help command.

In response to this:

in CAPI we can give some general guidelines, but documentation for each infrastructure should be implemented in each provider.

if we want to fix this properly, one possible approach is to implement additional validation webhooks for CAPI resources in providers, but this seems out of scope of the current request so eventually this + follow up discussions should be moved to a separated issue

/lifecycle frozen
/unassign @randomvariable
/help

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/test-infra repository.

@k8s-ci-robot k8s-ci-robot added lifecycle/frozen Indicates that an issue or PR should not be auto-closed due to staleness. help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Nov 3, 2022
@k8s-triage-robot
Copy link

This issue has not been updated in over 1 year, and should be re-triaged.

You can:

  • Confirm that this issue is still relevant with /triage accepted (org members only)
  • Close this issue with /close

For more details on the triage process, see https://www.kubernetes.dev/docs/guide/issue-triage/

/remove-triage accepted

@k8s-ci-robot k8s-ci-robot added needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. and removed triage/accepted Indicates an issue or PR is ready to be actively worked on. labels Jan 19, 2024
@fabriziopandini
Copy link
Member

/priority backlog

@k8s-ci-robot k8s-ci-robot added the priority/backlog Higher priority than priority/awaiting-more-evidence. label Apr 12, 2024
@fabriziopandini fabriziopandini removed the lifecycle/frozen Indicates that an issue or PR should not be auto-closed due to staleness. label Apr 24, 2024
@fabriziopandini
Copy link
Member

/triage accepted

Having guidelines like this will be super valuable for the entire Cluster API community.

We should also consider discussing a guideline about how which "root" use to compute infrastructure names (e.g machine or infrastructure machines, see e.g. the issue in #10463)

@k8s-ci-robot k8s-ci-robot added triage/accepted Indicates an issue or PR is ready to be actively worked on. and removed needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Apr 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. kind/documentation Categorizes issue or PR as related to documentation. priority/backlog Higher priority than priority/awaiting-more-evidence. triage/accepted Indicates an issue or PR is ready to be actively worked on.
Projects
None yet
Development

No branches or pull requests

4 participants