Skip to content

Commit fbb3c9b

Browse files
Merge pull request #1091 from rackerlabs/update-app-docs
docs: update appset documentation
2 parents 471c508 + 2dd825a commit fbb3c9b

File tree

2 files changed

+44
-48
lines changed

2 files changed

+44
-48
lines changed

docs/deploy-guide/add-remove-app.md

Lines changed: 44 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -23,66 +23,66 @@ in your deployment repo.
2323

2424
## Removing an application for a specific deploy
2525

26-
To remove an application from being deployed, add or modify the `uc_skip_components`
27-
annotation on the Kubernetes Secret which defines the cluster in the `argocd` namespace.
28-
The `uc_skip_components` annotation is a string-ified JSON list of applications to
29-
skip like:
26+
To remove an application from being deployed, create an `apps.yaml` file in your deployment
27+
repo at `$DEPLOY_NAME/apps.yaml`). The `apps.yaml` file
28+
contains a list of objects, where each object has a `component` field that is the name
29+
of the component (app) and an optional `skip` field that can be set to `true`:
3030

3131
```yaml
32-
uc_skip_components: |
33-
["metallb"]
32+
- component: metallb
33+
skip: true
34+
- component: dex
35+
skip: false # optional, defaults to false
3436
```
3537
3638
## Adding an application to UnderStack
3739
38-
Adding an application to be part of UnderStack involves modifying the
39-
`apps/appsets/*.yaml` file that is appropriate for what you are attempting to add.
40+
Adding an application to UnderStack involves deciding on the correct ApplicationSet
41+
(AppSet) to include it in, then going to that AppSet's directory in `apps/<appset>/`
42+
and adding a YAML file which contains the application configuration.
43+
44+
The YAML file should contain:
45+
46+
- A `component` field that matches the application name
47+
- All sources necessary to load the application
48+
- A `ref` field set to either `understack` or `deploy` instead of explicitly
49+
specifying `repoURL` and `targetRevision` for the UnderStack repo and your deploy repo
4050

41-
The general form should be:
51+
Example application configuration:
4252

4353
{% raw %}
4454

4555
```yaml
46-
# list item per ArgoCD Application
47-
# the component value will appear as the ArgoCD Application name
48-
- component: dex
49-
# the below line can be added to install this into a different namespace than the component
50-
# componentNamespace: dex-system
51-
# this allows this component to not be installed
52-
skipComponent: '{{has "dex" ((default "[]" (index .metadata.annotations "uc_skip_components") | fromJson))}}'
53-
# defines all the sources used, the upstream chart or upstream source should come first
54-
# uc_repo_ in this context is the understack repo
55-
# uc_deploy_ in this context is the deploy specific repo
56-
sources:
57-
- repoURL: https://charts.dexidp.io
58-
chart: dex
59-
targetRevision: 0.16.0
60-
helm:
61-
releaseName: dex
62-
valueFiles:
63-
# this pulls defaults from the understack repo
64-
- $understack/components/dex/values.yaml
65-
# this pulls overrides from your deploy repo
66-
- $deploy/{{.name}}/helm-configs/dex.yaml
67-
# this makes it so the above don't have to exist
68-
ignoreMissingValueFiles: true
69-
- repoURL: '{{index .metadata.annotations "uc_repo_git_url"}}'
70-
targetRevision: '{{index .metadata.annotations "uc_repo_ref"}}'
71-
# path should only be here if you have manifests you want loaded
72-
path: 'components/dex'
73-
# ref is used above in the chart for the valueFiles
74-
ref: understack
75-
- repoURL: '{{index .metadata.annotations "uc_deploy_git_url"}}'
76-
targetRevision: '{{index .metadata.annotations "uc_deploy_ref"}}'
77-
# ref is used in the chart valueFiles
78-
ref: deploy
79-
# only needed if manifests should be here
80-
path: '{{.name}}/manifests/dex'
56+
component: dex
57+
# optional: install into a different namespace than the component name
58+
# componentNamespace: dex-system
59+
sources:
60+
- repoURL: https://charts.dexidp.io
61+
chart: dex
62+
targetRevision: 0.16.0
63+
helm:
64+
releaseName: dex
65+
valueFiles:
66+
# pulls defaults from the understack repo
67+
- $understack/components/dex/values.yaml
68+
# pulls overrides from your deploy repo
69+
- $deploy/{{.name}}/helm-configs/dex.yaml
70+
ignoreMissingValueFiles: true
71+
- ref: understack
72+
# path should only be here if you have manifests to load
73+
path: 'components/dex'
74+
- ref: deploy
75+
# only needed if manifests should be here
76+
path: '{{.name}}/manifests/dex'
8177
```
8278

8379
{% endraw %}
8480

8581
## Removing an application from UnderStack
8682

83+
Removing an application permanently from UnderStack is as easy as
84+
deleting its YAML config from its AppSet in the `apps/<appset>/`
85+
directory.
86+
8787
[argocd]: <https://argo-cd.readthedocs.io/en/stable/>
8888
[argocd-appset]: <https://argo-cd.readthedocs.io/en/stable/operator-manual/applicationset/>

docs/deploy-guide/management-cluster.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -94,10 +94,6 @@ different configurations.
9494
: Git reference to use of the deploy repo. Can only be set for `dev` env
9595
clusters.
9696

97-
`uc_skip_components`
98-
: string-ified JSON list of components or services from UnderStack to not
99-
install in this cluster.
100-
10197
### Deploying your Cluster Config
10298

10399
Once you have the Kubernetes secret which defines your cluster config ready

0 commit comments

Comments
 (0)