Skip to content

Commit 71080df

Browse files
ejholmesclaude
andcommitted
Add demo for mani-diffy.chime.com/skip annotation
- Updated service.tpl to conditionally add the skip annotation - Added test-service-skipped with skipManiDiffy: true - Regenerated manifests showing the annotation in action Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
1 parent 212d52e commit 71080df

File tree

5 files changed

+35
-2
lines changed

5 files changed

+35
-2
lines changed

.github/workflows/generate-manifests-demos.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: Generate manifests for demo
22
on: [push]
33

44
env:
5-
USE_RELEASE: true
5+
USE_RELEASE: false
66
RELEASE_TAG: v0.1.1
77

88
jobs:

demo/.zz.auto-generated/test-app-group-1/manifest.yaml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,3 +70,29 @@ spec:
7070
- ../../overrides/service/foo/test.yaml
7171
syncPolicy:
7272
automated: {}
73+
---
74+
# Source: app-of-apps/templates/apps.yaml
75+
apiVersion: argoproj.io/v1alpha1
76+
kind: Application
77+
metadata:
78+
name: test-service-skipped
79+
annotations:
80+
mani-diffy.chime.com/skip: "true"
81+
spec:
82+
destination:
83+
namespace: argocd
84+
server: https://kubernetes.default.svc
85+
project: default
86+
source:
87+
repoURL: https://github.com/chime/mani-diffy.git
88+
path: charts/service
89+
helm:
90+
version: v3
91+
parameters:
92+
- name: env
93+
value: test
94+
valueFiles:
95+
- ../../overrides/service/skipped/base.yaml
96+
- ../../overrides/service/skipped/test.yaml
97+
syncPolicy:
98+
automated: {}

demo/charts/app-of-apps/templates/service.tpl

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,10 @@ apiVersion: argoproj.io/v1alpha1
55
kind: Application
66
metadata:
77
name: {{ .root.env }}-service-{{ $appName }}
8+
{{- if .childParams.skipManiDiffy }}
9+
annotations:
10+
mani-diffy.chime.com/skip: "true"
11+
{{- end }}
812
spec:
913
destination:
1014
namespace: argocd

demo/overrides/app-of-apps/test-app-group-1.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,6 @@ children:
55
chart: service
66
baz:
77
chart: service
8+
skipped:
9+
chart: service
10+
skipManiDiffy: true

pkg/helm/helm_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -321,7 +321,7 @@ kind: Application
321321
t.Run("GenerateHashOnChart", func(t *testing.T) {
322322
hash, _ := generalHashFunction("demo/charts/app-of-apps")
323323
h := hex.EncodeToString(hash)
324-
actualHash := "13aa148adefa3d633e5ce95584d3c95297a4417977837040cd67f0afbca17b5a"
324+
actualHash := "f57ffb63de221520249492e247beb6d6f61cd378e7c246909cca9c5110a6bb28"
325325
if h != actualHash {
326326
t.Errorf("Failed to generate a generic hash on a chart. got: %s wanted: %s", h, actualHash)
327327
}

0 commit comments

Comments
 (0)