CI: k8s: Set cert-manager cluster issuer

This commit is contained in:
Igor Scheller 2021-04-11 19:20:27 +02:00
parent 9349634802
commit d1408fc3fe
2 changed files with 2 additions and 0 deletions

View File

@ -317,6 +317,7 @@ deploy:
- export CI_PVC_SC=${CI_PVC_SC:-"${CI_PVC_SC_LOCAL:-local-path}"} - export CI_PVC_SC=${CI_PVC_SC:-"${CI_PVC_SC_LOCAL:-local-path}"}
- export CI_REPLICAS=${CI_REPLICAS_REVIEW:-${CI_REPLICAS:-2}} - export CI_REPLICAS=${CI_REPLICAS_REVIEW:-${CI_REPLICAS:-2}}
- export CI_APP_NAME=${CI_APP_NAME:-Engelsystem} - export CI_APP_NAME=${CI_APP_NAME:-Engelsystem}
- export CI_CLUSTER_ISSUER=${CI_CLUSTER_ISSUER:-letsencrypt}
- cp deployment.tpl.yaml deployment.yaml - cp deployment.tpl.yaml deployment.yaml
- for env in ${!CI_*}; do sed -i "s#<${env}>#$(echo "${!env}"|head -n1)#g" deployment.yaml; done - for env in ${!CI_*}; do sed -i "s#<${env}>#$(echo "${!env}"|head -n1)#g" deployment.yaml; done

View File

@ -186,6 +186,7 @@ metadata:
annotations: annotations:
kubernetes.io/tls-acme: 'true' kubernetes.io/tls-acme: 'true'
kubernetes.io/ingress.class: 'nginx' kubernetes.io/ingress.class: 'nginx'
cert-manager.io/cluster-issuer: <CI_CLUSTER_ISSUER>
nginx.ingress.kubernetes.io/rewrite-target: /$1 nginx.ingress.kubernetes.io/rewrite-target: /$1
labels: labels:
app: <CI_PROJECT_PATH_SLUG> app: <CI_PROJECT_PATH_SLUG>