File tree Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Original file line number Diff line number Diff line change 8080 - name : Install Package
8181 uses : ConorMacBride/install-package@main
8282 with :
83- apt : build-essential git unzip nodejs python3 python3-pip python3-wheel python-is-python3
83+ apt : git unzip nodejs
8484
8585 - uses : actions/checkout@v4
8686 with :
@@ -154,7 +154,17 @@ jobs:
154154 OS_APPLICATION_CREDENTIAL_SECRET : ${{ secrets.OS_APPLICATION_CREDENTIAL_SECRET }}
155155
156156 - name : Terraform Apply
157- run : terraform apply -auto-approve
157+ run : |
158+ for attempt in $(seq 5); do
159+ if terraform apply -auto-approve; then
160+ echo "Created infrastructure on attempt $attempt"
161+ break
162+ fi
163+ echo "Failed to create infrastructure on attempt $attempt"
164+ sleep 10
165+ terraform destroy -auto-approve
166+ sleep 60
167+ done
158168 working-directory : ${{ github.workspace }}/terraform/aio
159169 env :
160170 OS_CLOUD : ${{ inputs.OS_CLOUD }}
You can’t perform that action at this time.
0 commit comments