File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1313 chart-dir : ./helm
1414 chmod-kubeconfig : " 1" # `chmod 600 kubeconfig-filepath`
1515 cleanup : " 1" # delete all the files i.e. kubeconfig & values
16+ cleanup-on-fail : " 1" # delete newly created resources on failure
1617 create-namespace : " 0"
1718 helm-version : " v3.10.1" # https://github.com/helm/helm/releases
1819 namespace : default
1920 release-name : ${{ github.event.repository.name }}
21+ timeout : 10m
2022 update-dependencies : " 1" # helm dep update
2123 values : image.tag=${{ github.sha }} # comma separated key=value pairs
2224 values-string : key1=value1,key2=value2 # comma separated key=value pairs
Original file line number Diff line number Diff line change @@ -29,6 +29,10 @@ inputs:
2929 default : " 1"
3030 description : Whether or not to delete all the kubeconfig & values files after deployment
3131 required : false
32+ cleanup-on-fail :
33+ default : " 1"
34+ description : Whether or not to delete all the newly created resources on failure
35+ required : false
3236 create-namespace :
3337 default : " 0"
3438 description : Whether or not to pass `--create-namespace` to Helm
@@ -48,6 +52,9 @@ inputs:
4852 release-name :
4953 default : ${{ github.event.repository.name }}
5054 required : false
55+ timeout :
56+ default : 10m
57+ description : The maximum amount of time to wait for the deployment to complete
5158 update-dependencies :
5259 default : " 1"
5360 description : Whether or not to run `helm dependency update` before deployment
@@ -133,9 +140,11 @@ runs:
133140 helm ${{ inputs.action }} ${{ inputs.release-name }} ${{ inputs.chart-dir }} \
134141 --kubeconfig ${{ inputs.kubeconfig-filepath || steps.generate-random-filepath.outputs.KUBECONFIG_FILEPATH }} \
135142 --namespace ${{ inputs.namespace }} \
143+ --timeout ${{ inputs.timeout }} \
136144 $([[ "${{ inputs.create-namespace }}" == "1" ]] && echo '--create-namespace') \
137145 $([[ "${{ inputs.atomic }}" == "1" ]] && echo '--atomic') \
138146 $([[ "${{ inputs.wait }}" == "1" ]] && echo '--wait') \
147+ $([[ "${{ inputs.cleanup-on-fail }}" == "1" ]] && echo '--cleanup-on-fail') \
139148 $([[ "${{ inputs.values-file }}" != "" ]] && echo "--values ${{ github.run_id }}") \
140149 $([[ "${{ inputs.values-filepath }}" != "" ]] && echo "--values ${{ inputs.values-filepath }}") \
141150 $([[ "${{ inputs.values }}" != "" ]] && echo "--set ${{ inputs.values }}") \
You can’t perform that action at this time.
0 commit comments