11 lines
766 B
Bash
Executable file
11 lines
766 B
Bash
Executable file
#!/bin/bash
|
|
CERTMANAGER_VERSION=0.14.1
|
|
CERTMANAGER_SHORTVERSION="$(echo "${CERTMANAGER_VERSION}" | sed 's/^\(.*\)\.[0-9]$/\1/')"
|
|
cd "$(dirname ${0})"/../templates/
|
|
wget https://github.com/jetstack/cert-manager/releases/download/v"${CERTMANAGER_VERSION}"/cert-manager.yaml
|
|
kubernetes-split-yaml cert-manager.yaml > generated.log
|
|
mv generated "${CERTMANAGER_SHORTVERSION}"
|
|
cat generated.log | while read LIGNE; do if [ $(echo "${LIGNE}" | grep -c ^File) -eq 1 ]; then echo -n "${LIGNE} "; else echo "${LIGNE}"; fi; done | grep ^File | sort -V | sed 's|.*\(generated/\)\(.*\.yaml\)| - "'${CERTMANAGER_SHORTVERSION}'/\2"|'
|
|
|
|
sed '/args:/ a\ - --dns01-recursive-nameservers=8.8.8.8:53,1.1.1.1:53' -i "${CERTMANAGER_SHORTVERSION}"/cert-manager-Deployment.yaml
|
|
|