Skip to content

Commit c8034a8

Browse files
committed
ci: validate experimental and core manifests in sync
1 parent e692dd4 commit c8034a8

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

Makefile

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ NRLICENSE := $(TOOLS_BIN_DIR)/nrlicense
1919

2020
DISTRIBUTIONS ?= "nrdot-collector-host,nrdot-collector-k8s,nrdot-collector,nrdot-collector-experimental"
2121

22-
ci: check build build-fips version-check licenses-check
22+
ci: check manifests-check build build-fips version-check licenses-check
2323
check: ensure-goreleaser-up-to-date
2424

2525
build: go ocb
@@ -173,3 +173,16 @@ licenses-check: headers-check licenses
173173
exit 1;\
174174
} \
175175
|| exit 0
176+
177+
# Check if all core components are present in experimental manifest
178+
CORE_MANIFEST="${SRC_ROOT}/distributions/nrdot-collector/manifest.yaml"
179+
EXPERIMENTAL_MANIFEST="${SRC_ROOT}/distributions/nrdot-collector-experimental/manifest.yaml"
180+
.PHONY: manifests-check
181+
manifests-check:
182+
@diff=$$(yq 'del(.dist)' "${CORE_MANIFEST}" | \
183+
grep -vxF "$$(yq 'del(.dist)' "${EXPERIMENTAL_MANIFEST}")"); \
184+
[ -n "$${diff}" ] && { \
185+
echo "NRDOT Experimental manifest out of sync with Core. Diff:"; \
186+
echo "$${diff}"; \
187+
exit 1; \
188+
} || exit 0

0 commit comments

Comments
 (0)