reorder install to get vault setup properly

This commit is contained in:
Amarpreet Minhas 2022-12-31 02:59:52 +00:00
parent e92f54473f
commit fe4c4e8f4b
3 changed files with 28 additions and 29 deletions

View file

@ -18,14 +18,6 @@ EOH
vault policy write gitea gitea.hcl
rm gitea.hcl
helm upgrade --install \
gitea \
gitea-charts/gitea \
-f values.yaml \
-n ${NAMESPACE} \
--version ${CHART_VERSION} \
--cleanup-on-fail
HOST_IP=$(ip addr show eth0 | grep -Po 'inet \K[\d.]+')
TOKEN="$(kubectl get secret serviceaccounttoken -n gitea -o go-template='{{ .data.token }}' | base64 -d)"
@ -36,3 +28,11 @@ vault write auth/${VAULT_AUTH_NAMESPACE}/role/gitea \
ttl=24h
vault write auth/${VAULT_AUTH_NAMESPACE}/login role=gitea jwt=${TOKEN} iss=https://${HOST_IP}:6443
helm upgrade --install \
gitea \
gitea-charts/gitea \
-f values.yaml \
-n ${NAMESPACE} \
--version ${CHART_VERSION} \
--cleanup-on-fail

View file

@ -8,17 +8,6 @@ kubectl create ns ${NAMESPACE}
kubectl create serviceaccount -n ${NAMESPACE} miniflux
kubectl apply -n ${NAMESPACE} -f external-secrets.yaml
helm repo add gabe565 https://charts.gabe565.com
helm repo update
helm upgrade --install \
miniflux \
gabe565/miniflux \
-f values.yaml \
-n ${NAMESPACE} \
--version ${CHART_VERSION} \
--cleanup-on-fail
HOST_IP=$(ip addr show eth0 | grep -Po 'inet \K[\d.]+')
TOKEN="$(kubectl get secret serviceaccounttoken -n miniflux -o go-template='{{ .data.token }}' | base64 -d)"
@ -37,3 +26,14 @@ vault write auth/${VAULT_AUTH_NAMESPACE}/role/miniflux \
ttl=24h
vault write auth/${VAULT_AUTH_NAMESPACE}/login role=miniflux jwt=${TOKEN} iss=https://${HOST_IP}:6443
helm repo add gabe565 https://charts.gabe565.com
helm repo update
helm upgrade --install \
miniflux \
gabe565/miniflux \
-f values.yaml \
-n ${NAMESPACE} \
--version ${CHART_VERSION} \
--cleanup-on-fail

View file

@ -10,16 +10,6 @@ helm repo update
kubectl create ns wallabag
kubectl create serviceaccount -n ${NAMESPACE} wallabag
kubectl apply -n ${NAMESPACE} -f external-secrets.yaml
helm upgrade --install \
wallabag \
k8s-at-home/wallabag \
-f values.yaml \
-n ${NAMESPACE} \
--version ${CHART_VERSION} \
--cleanup-on-fail
#kubectl apply -n ${NAMESPACE} -f traefik.yaml
HOST_IP=$(ip addr show eth0 | grep -Po 'inet \K[\d.]+')
TOKEN="$(kubectl get secret serviceaccounttoken -n wallabag -o go-template='{{ .data.token }}' | base64 -d)"
@ -30,3 +20,12 @@ vault write auth/${VAULT_AUTH_NAMESPACE}/role/wallabag \
ttl=24h
vault write auth/${VAULT_AUTH_NAMESPACE}/login role=wallabag jwt=${TOKEN} iss=https://${HOST_IP}:6443
helm upgrade --install \
wallabag \
k8s-at-home/wallabag \
-f values.yaml \
-n ${NAMESPACE} \
--version ${CHART_VERSION} \
--cleanup-on-fail