chore: add managemnet plugins
This commit is contained in:
parent
e7fa2b19d8
commit
ad6486c49a
77
k8s-bootstrap/management-plugin-patch.yml
Normal file
77
k8s-bootstrap/management-plugin-patch.yml
Normal file
@ -0,0 +1,77 @@
|
|||||||
|
---
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: argocd-repo-server
|
||||||
|
namespace: argocd
|
||||||
|
spec:
|
||||||
|
template:
|
||||||
|
spec:
|
||||||
|
initContainers:
|
||||||
|
- name: download-copy-timoni
|
||||||
|
image: alpine/curl
|
||||||
|
command: [/bin/sh]
|
||||||
|
args:
|
||||||
|
- -c
|
||||||
|
- >-
|
||||||
|
curl -sLO https://github.com/stefanprodan/timoni/releases/download/v0.23.0/timoni_0.23.0_linux_$(arch | sed 's/aarch/arm/' | sed 's/x86_64/amd64/').tar.gz &&
|
||||||
|
tar -xzf timoni_0.23.0_linux_$(arch | sed 's/aarch/arm/' | sed 's/x86_64/amd64/').tar.gz -C /var/run/argocd/ timoni
|
||||||
|
volumeMounts:
|
||||||
|
- mountPath: /var/run/argocd
|
||||||
|
name: var-files
|
||||||
|
|
||||||
|
- name: copyutil
|
||||||
|
command: [ /bin/bash ]
|
||||||
|
args:
|
||||||
|
- -c
|
||||||
|
- >-
|
||||||
|
/bin/cp -n /usr/local/bin/helm /var/run/argocd/helm &&
|
||||||
|
/bin/cp -n /usr/local/bin/kustomize /var/run/argocd/kustomize &&
|
||||||
|
/bin/cp -n /usr/local/bin/argocd /var/run/argocd/argocd-cmp-server
|
||||||
|
volumeMounts:
|
||||||
|
- mountPath: /var/run/argocd
|
||||||
|
name: var-files
|
||||||
|
|
||||||
|
containers:
|
||||||
|
- name: timoni
|
||||||
|
image: alpine
|
||||||
|
securityContext:
|
||||||
|
runAsUser: 999
|
||||||
|
runAsNonRoot: true
|
||||||
|
imagePullPolicy: IfNotPresent
|
||||||
|
command: [/var/run/argocd/argocd-cmp-server]
|
||||||
|
volumeMounts:
|
||||||
|
- name: var-files
|
||||||
|
mountPath: /var/run/argocd
|
||||||
|
- name: plugins
|
||||||
|
mountPath: /home/argocd/cmp-server/plugins
|
||||||
|
- name: cmp-plugins
|
||||||
|
mountPath: /home/argocd/cmp-server/config/plugin.yaml
|
||||||
|
subPath: timoni.yml
|
||||||
|
- name: cmp-tmp
|
||||||
|
mountPath: /tmp
|
||||||
|
|
||||||
|
- name: kustomize-helm-enabled
|
||||||
|
image: alpine
|
||||||
|
securityContext:
|
||||||
|
runAsUser: 999
|
||||||
|
runAsNonRoot: true
|
||||||
|
imagePullPolicy: IfNotPresent
|
||||||
|
command: [/var/run/argocd/argocd-cmp-server]
|
||||||
|
volumeMounts:
|
||||||
|
- name: var-files
|
||||||
|
mountPath: /var/run/argocd
|
||||||
|
- name: plugins
|
||||||
|
mountPath: /home/argocd/cmp-server/plugins
|
||||||
|
- name: cmp-plugins
|
||||||
|
mountPath: /home/argocd/cmp-server/config/plugin.yaml
|
||||||
|
subPath: kustomize-helm-enabled.yml
|
||||||
|
- name: cmp-tmp
|
||||||
|
mountPath: /tmp
|
||||||
|
|
||||||
|
volumes:
|
||||||
|
- name: cmp-plugins
|
||||||
|
configMap:
|
||||||
|
name: argocd-custom-plugins
|
||||||
|
- name: cmp-tmp
|
||||||
|
emptyDir: {}
|
||||||
32
k8s-bootstrap/management-plugin.yml
Normal file
32
k8s-bootstrap/management-plugin.yml
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: ConfigMap
|
||||||
|
metadata:
|
||||||
|
name: argocd-custom-plugins
|
||||||
|
namespace: argocd
|
||||||
|
data:
|
||||||
|
timoni.yml: |
|
||||||
|
---
|
||||||
|
apiVersion: argoproj.io/v1alpha1
|
||||||
|
kind: ConfigManagementPlugin
|
||||||
|
metadata:
|
||||||
|
name: timoni
|
||||||
|
spec:
|
||||||
|
generate:
|
||||||
|
command:
|
||||||
|
- /bin/sh
|
||||||
|
- -c
|
||||||
|
- /var/run/argocd/timoni build $ARGOCD_APP_NAME $ARGOCD_APP_SOURCE_PATH
|
||||||
|
|
||||||
|
kustomize-helm-enabled.yml: |
|
||||||
|
---
|
||||||
|
apiVersion: argoproj.io/v1alpha1
|
||||||
|
kind: ConfigManagementPlugin
|
||||||
|
metadata:
|
||||||
|
name: kustomize-helm-enabled
|
||||||
|
spec:
|
||||||
|
generate:
|
||||||
|
command:
|
||||||
|
- /bin/sh
|
||||||
|
- -c
|
||||||
|
- /var/run/argocd/kustomize build --enable-helm
|
||||||
Loading…
x
Reference in New Issue
Block a user