Skip to content

Commit

Permalink
CLD-8407: skip override custom values if file exists
Browse files Browse the repository at this point in the history
  • Loading branch information
andrleite committed Oct 8, 2024
1 parent 009e4da commit cab1abd
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions aws/eks-customer/scripts/deploy-utility.sh
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,11 @@ function replace_custom_values () {
private_certificate_arn=$(escape_string ${PRIVATE_CERTIFICATE_ARN})
allow_list_cidr_range=$(escape_string ${ALLOW_LIST_CIDR_RANGE})

if [[ -f "$gitops_apps_dir/${ENV}/helm-values/${CLUSTER_NAME}/$utility_name-custom-values.yaml" ]]; then
echo "Custom values file already exists, skipping"
return
fi

if [[ -f $gitops_apps_dir/custom-values-template/$utility_name-custom-values.yaml-template ]]; then
cp $gitops_apps_dir/custom-values-template/$utility_name-custom-values.yaml-template $gitops_apps_dir/${ENV}/helm-values/${CLUSTER_NAME}/$utility_name-custom-values.yaml
sed -i -e "s/<CLUSTER_ID>/${CLUSTER_NAME}/g" \
Expand Down

0 comments on commit cab1abd

Please sign in to comment.