Skip to content
Snippets Groups Projects
Commit a8109dda authored by Alexey Lunin's avatar Alexey Lunin
Browse files

experiments

parent 83772564
No related branches found
No related tags found
No related merge requests found
helm install ocm-instance1 mychart/ -f ocm1-values.yaml #!/bin/bash
# Path to the Helm chart
CHART_PATH="."
# Get a list of all values-*.yaml files in the current directory
VALUES_FILES=$(ls values*.yaml)
# Loop over each values file
for VALUES_FILE in $VALUES_FILES
do
# Extract the base name without extension
BASE_NAME=$(basename "$VALUES_FILE" .yaml)
# Use the base name as the release name
RELEASE_NAME="ocm_$BASE_NAME"
# Run helm install with the found values file
echo "Deploying $RELEASE_NAME with $VALUES_FILE"
helm install "$RELEASE_NAME" "$CHART_PATH" -f "./$VALUES_FILE"
# Check for errors
if [ $? -ne 0 ]; then
echo "Helm install failed for $VALUES_FILE"
exit 1
fi
done
echo "Helm install completed for all values files."
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment