46 lines
1.1 KiB
YAML
46 lines
1.1 KiB
YAML
when:
|
|
event: push
|
|
matrix:
|
|
ENVIRONMENT:
|
|
- badhouseplants
|
|
- etersoft
|
|
steps:
|
|
diff:
|
|
image: ghcr.io/helmfile/helmfile:canary
|
|
secrets: [sops_age_key, kubeconfig_content]
|
|
when:
|
|
- branch:
|
|
exclude:
|
|
- main
|
|
commands:
|
|
- mkdir $HOME/.kube
|
|
- echo "$KUBECONFIG_CONTENT" > $HOME/.kube/config && chmod 0600 $HOME/.kube/config
|
|
- helmfile -e $ENVIRONMENT diff --suppress-secrets
|
|
|
|
notification:
|
|
image: deblan/woodpecker-email
|
|
settings:
|
|
from: woody@badhouseplants.net
|
|
host: badhouseplants.net
|
|
username:
|
|
from_secret: smtp_username
|
|
password:
|
|
from_secret: smtp_password
|
|
recipients:
|
|
- allanger@badhouseplants.net
|
|
subject: CDH result
|
|
target: main
|
|
when:
|
|
- status: [success, failure]
|
|
apply:
|
|
image: ghcr.io/helmfile/helmfile:canary
|
|
secrets: [sops_age_key, kubeconfig_content]
|
|
when:
|
|
- branch:
|
|
include:
|
|
- main
|
|
commands:
|
|
- mkdir $HOME/.kube
|
|
- echo "$KUBECONFIG_CONTENT" > $HOME/.kube/config && chmod 0600 $HOME/.kube/config
|
|
- helmfile -e $ENVIRONMENT apply
|