Add config template plugin examples (#7)

This commit is contained in:
Alexander Matyushentsev authored and GitHub committed 2019-02-25 14:19:08 -08:00
1 parent 179faabd63
commit 23eeb0925b
13 files changed
+116 -9

No files matched your search

+3
View File
@@ -0,0 +1,3 @@
all.yaml
charts
requirements.lock
+1
View File
@@ -0,0 +1 @@
name: guestbook
+30
View File
@@ -0,0 +1,30 @@
# Helm + Kustomize
Sometimes Helm chart don't have all required parameters and additional customization is required. This example application demonstrates how to combine Helm and Kustomize and use it
as a config management plugin in Argo CD.
Use following steps to try the application:
* configure `kustomized-helm` tool in `argocd-cm` ConfigMap:
```yaml
configManagementPlugins: |
- name: kustomized-helm
init:
command: [helm, dependency, build]
generate:
command: [sh, -c]
args: ["helm template . > all.yaml && kustomize build"]
```
* create application using `kustomized-helm` as a config management plugin name:
```
argocd app create kustomized-helm \
--config-management-plugin kustomized-helm \
--repo https://github.com/argoproj/argocd-example-apps \
--path plugins/kustomized-helm \
--dest-server https://kubernetes.default.svc \
--dest-namespace default
```
@@ -0,0 +1,7 @@
namePrefix: kustomize-
resources:
- ./all.yaml
patches:
- overlays/guestbook-deployment.yaml
@@ -0,0 +1,10 @@
apiVersion: apps/v1beta2
kind: Deployment
metadata:
name: release-name-helm-guestbook
spec:
template:
spec:
containers:
- name: helm-guestbook
image: "gcr.io/heptio-images/ks-guestbook-demo:0.2"
@@ -0,0 +1,4 @@
dependencies:
- name: helm-guestbook
version: 0.1.0
repository: file://../../helm-guestbook