Skip to content

Commit cca34bd

Browse files
committed
Add unmanaged infrastructure proposal
1 parent 0d4e430 commit cca34bd

File tree

1 file changed

+165
-0
lines changed

1 file changed

+165
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,165 @@
1+
---
2+
title: Unmanaged cluster infastructure
3+
authors:
4+
- "@enxebre"
5+
- "@joelspeed"
6+
- "@alexander-demichev"
7+
reviewers:
8+
- "@vincepri"
9+
- "@randomvariable"
10+
- "@CecileRobertMichon"
11+
- "@yastij"
12+
13+
creation-date: 2021-02-03
14+
last-updated: 2021-02-03
15+
status: implementable
16+
see-also:
17+
replaces:
18+
superseded-by:
19+
---
20+
21+
# Unmanaged cluster infrastucture
22+
23+
## Table of Contents
24+
25+
A table of contents is helpful for quickly jumping to sections of a proposal and for highlighting
26+
any additional information provided beyond the standard proposal template.
27+
[Tools for generating](https://github.com/ekalinin/github-markdown-toc) a table of contents from markdown are available.
28+
29+
- [Title](#title)
30+
- [Table of Contents](#table-of-contents)
31+
- [Glossary](#glossary)
32+
- [Summary](#summary)
33+
- [Motivation](#motivation)
34+
- [Goals](#goals)
35+
- [Non-Goals/Future Work](#non-goalsfuture-work)
36+
- [Proposal](#proposal)
37+
- [User Stories](#user-stories)
38+
- [Story 1](#story-1)
39+
- [Story 2](#story-2)
40+
- [Requirements (Optional)](#requirements-optional)
41+
- [Functional Requirements](#functional-requirements)
42+
- [FR1](#fr1)
43+
- [FR2](#fr2)
44+
- [Non-Functional Requirements](#non-functional-requirements)
45+
- [NFR1](#nfr1)
46+
- [NFR2](#nfr2)
47+
- [Implementation Details/Notes/Constraints](#implementation-detailsnotesconstraints)
48+
- [Security Model](#security-model)
49+
- [Risks and Mitigations](#risks-and-mitigations)
50+
- [Alternatives](#alternatives)
51+
- [Upgrade Strategy](#upgrade-strategy)
52+
- [Additional Details](#additional-details)
53+
- [Test Plan [optional]](#test-plan-optional)
54+
- [Graduation Criteria [optional]](#graduation-criteria-optional)
55+
- [Version Skew Strategy [optional]](#version-skew-strategy-optional)
56+
- [Implementation History](#implementation-history)
57+
58+
## Glossary
59+
60+
Refer to the [Cluster API Book Glossary](https://cluster-api.sigs.k8s.io/reference/glossary.html).
61+
62+
### Managed cluster infrastructure
63+
64+
Cluster infratructure which lifecycle is managed by a provider infraCluster CR.
65+
E.g in AWS:
66+
- Network
67+
- VPC
68+
- Subnets
69+
- Internet gateways
70+
- Nat gateways
71+
- Route tables
72+
- Security groups
73+
- Load balancers
74+
75+
### Unmanaged cluster infrastructure
76+
Cluster infratructure which lifecycle is not managed by CAPI but rather by an external entity.
77+
78+
## Summary
79+
80+
This proposal introduces first class support for "unmanaged" infrastructure for CAPI providers to consolidate the boundaries between managed and unmanaged cluster infrastructure.
81+
82+
## Motivation
83+
84+
Currently, Cluster API infrastructure providers support an opinionated happy path to create and manage cluster infrastructure lifecycle. The fundamental use case we want to support is out of tree controllers or tools that can manage the infrastructure bits.
85+
86+
This will ease adoption of CAPI in heterogeneous real world environments with restricted privileges and where the provider infrastructure for the cluster needs to be managed out of band.
87+
88+
### Goals
89+
90+
- Introduce support for "unmanaged" infrastructure consistently across CAPI providers.
91+
- The machine controller must be able to operate and manage machines when the infastructure is "unmanaged".
92+
93+
### Non-Goals/Future Work
94+
95+
- Modify existing managed behaviour.
96+
97+
## Proposal
98+
99+
Providers will add a `ManagementPolicy=Managed|Unmanaged` field to the provider infraCluster spec.
100+
101+
An "unmanaged" CAPI infraCluster won't reconcile or manage the lifecycle of the cluster infrastructure, but CAPI will be able to create compute nodes within it.
102+
103+
The machine controller must be able to operate without hard dependencies regardless of the cluster infrastructure being managed or unmanaged.
104+
![](https://i.imgur.com/nA61XJt.png)
105+
106+
### User Stories
107+
108+
#### Story 1 - Alternate control plane provisioning with user managed infrastructure
109+
As a cluster provider I want to use CAPI in my service offering to orchestrate Kubernetes bootstraping while letting workload cluster operators own their infrastructure lifecycle.
110+
111+
#### Story 2 - Restricted access to cloud provider APIs
112+
As a cluster operator I want to use CAPI to orchestrate kubernetes bootstraping while restricting the privileges I need to grant for my cloud provider because of organisational cloud security constraints.
113+
114+
#### Story 3 - Consuming existing cloud infrastructure
115+
As a cluster operator I want to use CAPI to orchestate Kubernetes bootstraping while reusing infrastructure that has already been created in the organisation either by me or another team.
116+
117+
### Implementation Details/Notes/Constraints
118+
119+
**Managed**
120+
- It will be default and will preserve existing behaviour.
121+
122+
**Unmanaged**
123+
124+
- The provider infraCluster controller will skip any infrastructure reconciliation.
125+
126+
- The provider infraCluster will set readiness to true.
127+
128+
- The provider infraCluster will set a condition unamangedReady to true.
129+
130+
- CAPI will proceed with further reconciliation as usual.
131+
132+
133+
### Security Model
134+
135+
When unmanaged no additional privileges for a cloud provider need to be given to CAPI other than the required to manage machines.
136+
137+
### Risks and Mitigations
138+
139+
140+
## Alternatives
141+
142+
We could have and adhoc CRD https://github.com/kubernetes-sigs/cluster-api/issues/4095
143+
144+
This would introduce complexity for the CAPI ecosystem with yet an additional CRD and it woudn't scale well across providers as it would need to contain provider specific information.
145+
146+
## Upgrade Strategy
147+
148+
Support is introduced by adding a new field for the provider infraCluster.
149+
150+
This makes any transition backward compatible and leave the current managed behaviour untouched.
151+
152+
The new field will be optional and default to "managed"
153+
154+
## Additional Details
155+
156+
## Implementation History
157+
158+
- [ ] MM/DD/YYYY: Proposed idea in an issue or [community meeting]
159+
- [ ] MM/DD/YYYY: Compile a Google Doc following the CAEP template (link here)
160+
- [ ] MM/DD/YYYY: First round of feedback from community
161+
- [ ] MM/DD/YYYY: Present proposal at a [community meeting]
162+
- [ ] MM/DD/YYYY: Open proposal PR
163+
164+
<!-- Links -->
165+
[community meeting]: https://docs.google.com/document/d/1Ys-DOR5UsgbMEeciuG0HOgDQc8kZsaWIWJeKJ1-UfbY

0 commit comments

Comments
 (0)