Skip to content

Commit

Permalink
feat: retry rsync push if fails
Browse files Browse the repository at this point in the history
  • Loading branch information
Regolith Linux committed May 19, 2024
1 parent 63e3c53 commit 362d122
Showing 1 changed file with 16 additions and 11 deletions.
27 changes: 16 additions & 11 deletions .github/workflows/build-deb-v4.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,18 +14,18 @@ jobs:
matrix:
stage: [experimental, unstable, testing ] # release-3_1, release-3_0, release-2_2, release-2_1]
distro-codename: [
ubuntu-focal-amd64,
ubuntu-focal-arm64,
ubuntu-jammy-amd64,
ubuntu-jammy-arm64,
ubuntu-focal-amd64,
ubuntu-focal-arm64,
ubuntu-jammy-amd64,
ubuntu-jammy-arm64,
ubuntu-noble-amd64,
ubuntu-noble-arm64,
debian-bullseye-amd64,
debian-bullseye-arm64,
debian-bookworm-amd64,
debian-bookworm-arm64,
debian-testing-amd64,
debian-testing-arm64
debian-testing-arm64
]
exclude:
- stage: release-3_1
Expand All @@ -35,7 +35,7 @@ jobs:
- stage: release-3_1
distro-codename: ubuntu-noble-arm64 # enable w/ 3.2
- stage: release-3_1
distro-codename: ubuntu-noble-amd64
distro-codename: ubuntu-noble-amd64
include:
- distro-codename: ubuntu-focal-amd64
host-os: ubuntu-20.04
Expand Down Expand Up @@ -136,7 +136,7 @@ jobs:
sudo rm /etc/apt/sources.list.d/regolith-local.list
echo "Cleaned up temp apt repo"
fi

sudo apt update
DEBIAN_FRONTEND=noninteractive sudo apt install -y --no-install-recommends jq git devscripts reprepro wget dput
- name: Pull Manifest
Expand Down Expand Up @@ -217,10 +217,15 @@ jobs:
fi
- name: Deploy via rsync
if: steps.changes.outputs.changed == 1
run: |
set -e
set -x
rsync -avzh ${{ steps.init.outputs.PKG_REPO_PATH }}/* root@${{ secrets.KAMATERA_HOSTNAME }}:/var/www/html/${{ steps.init.outputs.target }}
uses: nick-fields/retry@v3
with:
max_attempts: 10
retry_on: error
timeout_seconds: 5
command: |
set -e
set -x
rsync -avzh ${{ steps.init.outputs.PKG_REPO_PATH }}/* root@${{ secrets.KAMATERA_HOSTNAME }}:/var/www/html/${{ steps.init.outputs.target }}
- name: Log Build Output
if: steps.changes.outputs.changed == 1
run: |
Expand Down

0 comments on commit 362d122

Please sign in to comment.