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

clusterctl move support for cluster-scoped global resources #3081

Closed
randomvariable opened this issue May 21, 2020 · 12 comments
Closed

clusterctl move support for cluster-scoped global resources #3081

randomvariable opened this issue May 21, 2020 · 12 comments
Assignees
Labels
area/clusterctl Issues or PRs related to clusterctl kind/feature Categorizes issue or PR as related to a new feature. lifecycle/frozen Indicates that an issue or PR should not be auto-closed due to staleness.
Milestone

Comments

@randomvariable
Copy link
Member

User Story

As a cluster operator using AWS as per kubernetes-sigs/cluster-api-provider-aws#1713, I reference a cluster-scoped resource in my AWSCluster object. When I use clusterctl move, I want my cluster-scoped resource to be copied to the target cluster so Cluster API continues running.

Detailed Description

New in kubernetes-sigs/cluster-api-provider-aws#1713 is the use of cluster-scoped account principal resources for credential management for CAPA. clusterctl will need to be extended to support the copy of the cluster scoped resource to the target cluster when it exists as an owner reference on the AWSCluster resource.

For CAPA's purposes, a deletion of the original principal is not needed, and it is OK-ish for the cluster resource to be potentially mutated in the source cluster and another namespace moved to the target cluster and the cluster-scoped resource to be re-copied.

Anything else you would like to add:

This is by no means an exhaustive description of what needs to be done, but more a starter for ten (e.g. this also potentially affects ClusterResourceSet in a different way)

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

/kind feature

@k8s-ci-robot k8s-ci-robot added the kind/feature Categorizes issue or PR as related to a new feature. label May 21, 2020
@vincepri
Copy link
Member

vincepri commented May 21, 2020

/milestone v0.3.x

@vincepri vincepri added this to the v0.3.x milestone May 21, 2020
@kubernetes-sigs kubernetes-sigs deleted a comment from k8s-ci-robot May 21, 2020
@fabriziopandini
Copy link
Member

some background about the move operation:

  • the move operation is based on an object graph,
  • graph's nodes are all the object of kinds defined by CRDs installed by clusterctl + Secrets & ConfigMaps
  • graph's edges are based on OwnerReferences
  • nodes not linked to a cluster directly or in-directly are excluded from move
  • graphs relations are used to determine the create/delete order

in order to address this issue:
a. new types should be installed by clusterctl (I assume this is already the case)
b. it is required that objects are related via OwnerReferences
c. according to b, we should ensure that new objects are detected as in scope for move (not excluded)
d. eventual special case for global resources should be implemented (e.g. don't delete from source)

@fabriziopandini
Copy link
Member

fabriziopandini commented May 22, 2020

nb. a similar change might be required for ClusterResourceSet as well.
/cc @sedefsavas

@gab-satchi
Copy link
Member

/assign

@vincepri
Copy link
Member

@gab-satchi Before we start implementation, let's discuss a little more about the use case & proposed solution

@gab-satchi gab-satchi removed their assignment Jun 24, 2020
@fabriziopandini
Copy link
Member

/lifecycle active
/assign

@k8s-ci-robot k8s-ci-robot added the lifecycle/active Indicates that an issue or PR is actively being worked on by a contributor. label Jun 24, 2020
@vincepri
Copy link
Member

vincepri commented Aug 3, 2020

/milestone v0.4.0

@k8s-ci-robot k8s-ci-robot modified the milestones: v0.3.x, v0.4.0 Aug 3, 2020
@vincepri vincepri removed the lifecycle/active Indicates that an issue or PR is actively being worked on by a contributor. label Aug 3, 2020
@fejta-bot
Copy link

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/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 1, 2020
@fabriziopandini
Copy link
Member

/remove-lifecycle stale
/lifecycle frozen

@k8s-ci-robot k8s-ci-robot added lifecycle/frozen Indicates that an issue or PR should not be auto-closed due to staleness. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Nov 1, 2020
@fabriziopandini
Copy link
Member

/area clusterctl

@fabriziopandini
Copy link
Member

/close
in favour of #3042 (see #3042 (comment) for latest decisions)

@k8s-ci-robot
Copy link
Contributor

@fabriziopandini: Closing this issue.

In response to this:

/close
in favour of #3042 (see #3042 (comment) for latest decisions)

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/clusterctl Issues or PRs related to clusterctl kind/feature Categorizes issue or PR as related to a new feature. lifecycle/frozen Indicates that an issue or PR should not be auto-closed due to staleness.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants