Skip to content

Commit 6b776e3

Browse files
committed
openyurt application delivery feature
Signed-off-by: huiwq1990 <[email protected]>
1 parent 903b30d commit 6b776e3

File tree

1 file changed

+116
-0
lines changed

1 file changed

+116
-0
lines changed
Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,116 @@
1+
---
2+
title: Proposal Template
3+
authors:
4+
- "@huiwq1990"
5+
reviewers:
6+
- "@rambohe-ch"
7+
creation-date: 2022-06-11
8+
last-updated: 2022-06-11
9+
status: provisional
10+
---
11+
12+
# OpenYurt Application Delivery
13+
14+
## Table of Contents
15+
16+
A table of contents is helpful for quickly jumping to sections of a proposal and for highlighting
17+
any additional information provided beyond the standard proposal template.
18+
[Tools for generating](https://github.com/ekalinin/github-markdown-toc) a table of contents from markdown are available.
19+
20+
- [Title](#title)
21+
- [Table of Contents](#table-of-contents)
22+
- [Glossary](#glossary)
23+
- [Summary](#summary)
24+
- [Motivation](#motivation)
25+
- [Goals](#goals)
26+
- [Non-Goals/Future Work](#non-goalsfuture-work)
27+
- [Proposal](#proposal)
28+
- [User Stories](#user-stories)
29+
- [Implementation Details](#implementation-detailsnotesconstraints)
30+
- [OpenYurt Self-Defined Method](#goals)
31+
- [KubeVela Method](#goals)
32+
33+
## Glossary
34+
35+
Refer to the [Open Application Model](https://oam.dev/).
36+
37+
## Summary
38+
39+
Applications are usually a combine of workload,ingress,service etc. OpenYurt provides some workload controllers, but it's not friendly for application developers.
40+
41+
In this proposal, we would like to introduce an application controller which could delivery applications and consider openyurt cluster's features.
42+
43+
## Motivation
44+
45+
Currently, project `yurt-app-manager` deploys `ingress-controller` instances to every nodepool, project `yurt-edgex-manager` deploys `edgex` instances to every nodepool. So we could find the common ground is delivery resources to nodepool and the feature is useful if we want to develop new moduel as edge gateway.
46+
47+
By the way, `uniteddeployment` has the nodepool featrue, but it could only deploy one deployment or statefulset workload, not include other resrouces.
48+
49+
How to deploy resource collections, the most common way is use helm chart. `FluxCD` already implement the `HelmRelease` controller, but it's not support nodepool feature.
50+
51+
After investigation, we find out [OAM](https://oam.dev/) and [kubevela](https://kubevela.io/). Kubevela already defines application modules, and could delivery helm charts to multi-clusters. So if kubevela could deploy application to multi-nodepools, it will satisfy our requests.
52+
53+
### Goals
54+
55+
- Openyurt support application deploy
56+
- Both ingress-controller and edgex could use the controller to deploy
57+
58+
### Non-Goals/Future Work
59+
60+
- Treat application as a whole, application's inner resource not support reconcile
61+
62+
## Proposal
63+
64+
### User Stories
65+
66+
- Package kubernetes resources as a helm chart, and create application crd instance
67+
68+
### Implementation Details
69+
70+
#### OpenYurt Self-Defined Method
71+
72+
Define openyurt's application module and develop the application controller.
73+
74+
```yaml
75+
apiVersion: apps.openyurt.io/v1alpha1
76+
kind: Application
77+
metadata:
78+
name: helm-hello
79+
spec:
80+
spec:
81+
interval: 5m
82+
chart:
83+
spec:
84+
chart: chartmuseum
85+
version: "2.14.2"
86+
url: "https://jhidalgo3.github.io/helm-charts/"
87+
values: {}
88+
policies:
89+
nodepools: ["hangzhou","beijing"]
90+
```
91+
92+
#### KubeVela Method
93+
94+
As kubevela already implements application deploy, and application policies. We could extend nodepool policy type to implement.
95+
96+
```yaml
97+
apiVersion: core.oam.dev/v1beta1
98+
kind: Application
99+
metadata:
100+
name: helm-hello
101+
spec:
102+
components:
103+
- name: hello
104+
type: helm
105+
properties:
106+
repoType: "helm"
107+
url: "https://jhidalgo3.github.io/helm-charts/"
108+
chart: "hello-kubernetes-chart"
109+
version: "3.0.0"
110+
policies:
111+
- name: foo-cluster-only
112+
type: topology
113+
properties:
114+
clusters: ["foo"]
115+
```
116+

0 commit comments

Comments
 (0)