doc(team): changed the sub-helmfile as template (#524)
try to make the doc more clear.
This commit is contained in:
parent
14a392666e
commit
57df25c3ff
|
|
@ -121,7 +121,7 @@ releases:
|
||||||
|
|
||||||
You can go even further by generalizing the product related releases as a pair of `api` and `web`:
|
You can go even further by generalizing the product related releases as a pair of `api` and `web`:
|
||||||
|
|
||||||
`product/helmfile.yaml`:
|
`shared/helmfile.yaml`:
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
releases:
|
releases:
|
||||||
|
|
@ -133,28 +133,20 @@ releases:
|
||||||
# snip
|
# snip
|
||||||
```
|
```
|
||||||
|
|
||||||
And reusing it from the two product helmfiles:
|
Then you only need one single product helmfile
|
||||||
|
|
||||||
|
|
||||||
`product1/helmfile.yaml`:
|
`product/helmfile.yaml`:
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
helmfiles:
|
helmfiles:
|
||||||
- ../observability/helmfile.yaml
|
- ../observability/helmfile.yaml
|
||||||
- ../product/helmfile.yaml
|
- ../shared/helmfile.yaml
|
||||||
```
|
|
||||||
|
|
||||||
`product2/helmfile.yaml`:
|
|
||||||
|
|
||||||
```yaml
|
|
||||||
helmfiles:
|
|
||||||
- ../observability/helmfile.yaml
|
|
||||||
- ../product/helmfile.yaml
|
|
||||||
```
|
```
|
||||||
|
|
||||||
Now that we use the environment variable `PRODUCT_ID` to as the parameters of release names, you need to set it before running `helmfile`, so that it produces the differently named releases per product:
|
Now that we use the environment variable `PRODUCT_ID` to as the parameters of release names, you need to set it before running `helmfile`, so that it produces the differently named releases per product:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ PRODUCT_ID=1 helmfile -f product1/helmfile.yaml apply
|
$ PRODUCT_ID=1 helmfile -f product/helmfile.yaml apply
|
||||||
$ PRODUCT_ID=2 helmfile -f product2/helmfile.yaml apply
|
$ PRODUCT_ID=2 helmfile -f product/helmfile.yaml apply
|
||||||
```
|
```
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue