Squashed 'acm-hub-bootstrap/' content from commit 4b79b1a0
git-subtree-dir: acm-hub-bootstrap git-subtree-split: 4b79b1a0be6da2a9efc9ace8871b4762342da70b
This commit is contained in:
16
common/scripts/determine-main-clustergroup.sh
Executable file
16
common/scripts/determine-main-clustergroup.sh
Executable file
@@ -0,0 +1,16 @@
|
||||
#!/bin/bash
|
||||
|
||||
PATTERN_DIR="$1"
|
||||
|
||||
if [ -z "$PATTERN_DIR" ]; then
|
||||
PATTERN_DIR="."
|
||||
fi
|
||||
|
||||
CGNAME=$(yq '.main.clusterGroupName' "$PATTERN_DIR/values-global.yaml")
|
||||
|
||||
if [ -z "$CGNAME" ] || [ "$CGNAME" == "null" ]; then
|
||||
echo "Error - cannot detrmine clusterGroupName"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "$CGNAME"
|
||||
Reference in New Issue
Block a user