-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: github-actions <[email protected]>
- Loading branch information
1 parent
29b7559
commit 4da32db
Showing
8 changed files
with
99 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# DO NOT EDIT. Generated with: | ||
# | ||
# [email protected] | ||
# | ||
name: 'Check if values schema file has been updated' | ||
on: pull_request | ||
|
||
jobs: | ||
check: | ||
name: 'Check values.yaml and its schema in PR' | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: 'Checkout' | ||
uses: actions/checkout@v3 | ||
- name: 'Check if values.schema.json was updated' | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
VALUES_FILE_CHANGED="false" | ||
SCHEMA_FILE_CHANGED="false" | ||
base_ref=${GITHUB_BASE_REF##*/} | ||
head_ref=${GITHUB_HEAD_REF##*/} | ||
echo "Comparing ${base_ref}...${head_ref}" | ||
changed_files=$(gh api repos/{owner}/{repo}/compare/${base_ref}...${head_ref} --jq ".files[] | .filename") | ||
if grep -q "values.schema.json" <<< $(git ls-tree -r --name-only ${GITHUB_SHA}); then | ||
if grep -q "values.yaml" <<< "${changed_files}" ; then | ||
VALUES_FILE_CHANGED="true" | ||
fi | ||
if grep -q "values.schema.json" <<< "${changed_files}" ; then | ||
SCHEMA_FILE_CHANGED="true" | ||
fi | ||
if [ $VALUES_FILE_CHANGED != $SCHEMA_FILE_CHANGED ]; then | ||
echo "FAILED: values.yaml was updated but values.schema.json hasn't been regenerated" | ||
echo "Please refer to this document: https://intranet.giantswarm.io/docs/organizational-structure/teams/cabbage/app-updates/helm-values-schema/" | ||
exit 1 | ||
fi | ||
echo "PASSED: values.yaml and values.schema.json both appear to have been updated" | ||
exit 0 | ||
fi | ||
echo "INFO: values.schema.json not present in this repo - nothing to do" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
# DO NOT EDIT. Generated with: | ||
# | ||
# devctl@4.21.0 | ||
# devctl@4.23.0 | ||
# | ||
name: Create Release | ||
on: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
# DO NOT EDIT. Generated with: | ||
# | ||
# devctl@4.21.0 | ||
# devctl@4.23.0 | ||
# | ||
name: Create Release PR | ||
on: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
# DO NOT EDIT. Generated with: | ||
# | ||
# devctl@4.21.0 | ||
# devctl@4.23.0 | ||
# | ||
name: gitleaks | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
# DO NOT EDIT. Generated with: | ||
# | ||
# devctl@4.21.0 | ||
# devctl@4.23.0 | ||
# | ||
|
||
include Makefile.*.mk | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
# DO NOT EDIT. Generated with: | ||
# | ||
# devctl@4.21.0 | ||
# devctl@4.23.0 | ||
# | ||
|
||
##@ App | ||
|