Compare commits
No commits in common. "375fba63230c021e141b1b657d59608b885a64eb" and "809d26349bbb450b0648c623258cee4878fc3f4c" have entirely different histories.
375fba6323
...
809d26349b
@ -16,31 +16,11 @@ jobs:
|
|||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
- name: Download Artifacts
|
- name: Download Build Artifacts
|
||||||
run: |
|
uses: actions/download-artifact@v3
|
||||||
mkdir -p /workspace/unkin/terraform-nomad/plans
|
with:
|
||||||
export RUN_ID=$((GITHUB_RUN_NUMBER - 1))
|
name: plans
|
||||||
export PLANS_URL="https://git.query.consul/${GITHUB_REPOSITORY}/actions/runs/${RUN_ID}/artifacts/plans"
|
path: /workspace/unkin/terraform-nomad/plans
|
||||||
export MAX_RETRIES=5
|
|
||||||
export RETRY_COUNT=0
|
|
||||||
echo "Attempting to download plans from ${PLANS_URL}"
|
|
||||||
while [ $RETRY_COUNT -lt $MAX_RETRIES ]; do
|
|
||||||
curl -L -o /workspace/plans.zip "${PLANS_URL}" && break || true
|
|
||||||
echo "Plans file not available yet. Retrying in 10 seconds... ($((RETRY_COUNT + 1))/$MAX_RETRIES)"
|
|
||||||
RETRY_COUNT=$((RETRY_COUNT + 1))
|
|
||||||
sleep 10
|
|
||||||
done
|
|
||||||
if [ ! -f /workspace/plans.zip ]; then
|
|
||||||
echo "Failed to download plans file after $MAX_RETRIES attempts."
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
echo "Plans file downloaded. Extracting..."
|
|
||||||
unzip /workspace/plans.zip -d /workspace/unkin/terraform-nomad/plans
|
|
||||||
echo "Plans file extracted successfully."
|
|
||||||
|
|
||||||
- name: Show Plans
|
|
||||||
run: |
|
|
||||||
find /workspace -type f -name "*.plan"
|
|
||||||
|
|
||||||
- name: Install Packages
|
- name: Install Packages
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user