Skip to content

Commit

Permalink
ci: Add diff pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
jkroepke committed Jul 21, 2024
1 parent 8cd4338 commit fd4876c
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/lint-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,14 @@ jobs:
- name: Run chart-testing (diff)
if: steps.list-changed.outputs.changed == 'true'
run: |
changed_list=$(echo $changed_list)
for chart in $changed_list; do
helm install $chart oci://ghcr.io/${{ github.repository_owner }}/charts/$chart --create-namespace --namespace $chart --wait
helm diff upgrade $chart charts/$chart \
echo "installing chart: $chart"
chart="${chart#*/}"
helm install --create-namespace --namespace "${chart}" \
"${chart}" "oci://ghcr.io/${{ github.repository_owner }}/charts/$chart"
helm diff upgrade "${chart}" "charts/${chart}" \
--namespace $chart \
--suppress=CustomResourceDefinition \
--normalize-manifests \
Expand Down
2 changes: 1 addition & 1 deletion charts/github-actions-runner/templates/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ metadata:
labels:
{{- include "github-actions-runner.labels" . | nindent 4 }}
data:
{{ .Files.AsConfig "files/*.sh" | nindent 2 }}
{{ (.Files.Glob "files/*.sh").AsConfig | nindent 2 }}
2 changes: 1 addition & 1 deletion charts/github-actions-runner/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ spec:
- "service"
env:
{{- range $key, $val := .Values.env }}
{{- if ne (eq $val "") }}
{{- if not (eq (print $val) "") }}
- name: {{ $key }}
value: {{ $val | quote }}
{{- end }}
Expand Down

0 comments on commit fd4876c

Please sign in to comment.