Add Templates to pretty config
This commit is contained in:
parent
8bed95dd3e
commit
815ae64e32
@ -11,7 +11,7 @@ configVersion: v1
|
|||||||
kubernetes:
|
kubernetes:
|
||||||
- name: Watch application configmaps getting created
|
- name: Watch application configmaps getting created
|
||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
kind: ConfigMap
|
kind: Secret
|
||||||
executeHookOnSynchronization: false
|
executeHookOnSynchronization: false
|
||||||
executeHookOnEvent: ["Added", "Modified"]
|
executeHookOnEvent: ["Added", "Modified"]
|
||||||
jqFilter: ".data"
|
jqFilter: ".data"
|
||||||
@ -27,7 +27,5 @@ else
|
|||||||
export SP_ENVIRONMENT=$(jq -r .[0].object.metadata.name $BINDING_CONTEXT_PATH)
|
export SP_ENVIRONMENT=$(jq -r .[0].object.metadata.name $BINDING_CONTEXT_PATH)
|
||||||
export SP_APPLICATION=$(jq -r .[0].object.data.values $BINDING_CONTEXT_PATH | base64 -d | yq '.helm.release')
|
export SP_APPLICATION=$(jq -r .[0].object.data.values $BINDING_CONTEXT_PATH | base64 -d | yq '.helm.release')
|
||||||
envsubst < /tpls/flux-create.yaml | kubectl create -f -
|
envsubst < /tpls/flux-create.yaml | kubectl create -f -
|
||||||
kubectl patch configmap -n ${SP_CUSTOMER_ID} ${SP_ENVIRONMENT} \
|
|
||||||
-p '{"metadata":{"finalizers":["softplayer.net/bootstrapped"]}}' --type=merge
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -27,6 +27,7 @@ else
|
|||||||
echo "ERROR: template not found for ${SP_PROVIDER}-${SP_KUBERNETES}"
|
echo "ERROR: template not found for ${SP_PROVIDER}-${SP_KUBERNETES}"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
export SP_CUSTOMER_ID=$(jq -r .[0].object.metadata.namespace $BINDING_CONTEXT_PATH)
|
export SP_CUSTOMER_ID=$(jq -r .[0].object.metadata.namespace $BINDING_CONTEXT_PATH)
|
||||||
export SP_ENVIRONMENT=$(jq -r .[0].object.metadata.name $BINDING_CONTEXT_PATH)
|
export SP_ENVIRONMENT=$(jq -r .[0].object.metadata.name $BINDING_CONTEXT_PATH)
|
||||||
envsubst < /tpls/${SP_PROVIDER}-${SP_KUBERNETES}.yaml | kubectl create -f -
|
envsubst < /tpls/${SP_PROVIDER}-${SP_KUBERNETES}.yaml | kubectl create -f -
|
||||||
|
Loading…
Reference in New Issue
Block a user