diff --git a/.github/workflows/deploy.yaml b/.github/workflows/deploy.yaml index 10ed202..fe35864 100644 --- a/.github/workflows/deploy.yaml +++ b/.github/workflows/deploy.yaml @@ -133,6 +133,23 @@ jobs: - name: Helm Upgrade run: | + region_values='' + if [[ -e "./${{ inputs.chart_path }}/values/${{ inputs.env }}-${{ inputs.region }}.yaml" ]]; then + region_values=--values=./${{ inputs.chart_path }}/values/${{ inputs.env }}-${{ inputs.region }}.yaml + fi + standard_values='' + if [[ "${{inputs.helm_inject_standard_deploy_values}}" == "true" ]]; then + standard_values="--set-string imageName=${{ inputs.registry }} --set-string imageTag=${{ inputs.tag }} --set-string deployment.region=${{ inputs.region }}" + fi + helm upgrade ${{ inputs.chart_name }} ${{ inputs.chart_path }} --install --wait --atomic --cleanup-on-fail \ + --kubeconfig=./kubeconfig_${{ inputs.env }}_${{ inputs.region }} \ + --namespace=${{ inputs.chart_namespace }} \ + --values=./${{ inputs.chart_path }}/values/${{ inputs.env }}.yaml \ + --timeout ${{ inputs.helm_timeout }} \ + ${region_values} \ + ${standard_values} \ + ${{ inputs.helm_ext_args }} + region_values='' if [[ -e "./${{ inputs.chart_path }}/values/${{ inputs.env }}-${{ inputs.region }}.yaml" ]]; then region_values=--values="./${{ inputs.chart_path }}/values/${{ inputs.env }}-${{ inputs.region }}.yaml"