Skip to content
This repository was archived by the owner on Mar 28, 2026. It is now read-only.

Commit 78abb6d

Browse files
committed
Add retry logic to dmg create.
1 parent 84c6609 commit 78abb6d

1 file changed

Lines changed: 13 additions & 2 deletions

File tree

.github/workflows/main.yml

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,18 @@ jobs:
2828
python3 ./scripts/fix-webengine.py ./build/output/Jellyfin\ Media\ Player.app
2929
codesign --force --deep -s - ./build/output/Jellyfin\ Media\ Player.app/
3030
brew install create-dmg
31-
create-dmg --volname "Jellyfin Media Player" --no-internet-enable "JellyfinMediaPlayer.dmg" "./build/output/Jellyfin Media Player.app"
31+
attempts=0
32+
while [[ "$attempts" -lt 10 ]]
33+
do
34+
attempts=$((attempts+1))
35+
create-dmg --volname "Jellyfin Media Player" --no-internet-enable "JellyfinMediaPlayer.dmg" "./build/output/Jellyfin Media Player.app" && break || echo "dmg create failed, retrying..."
36+
sleep 5
37+
done
38+
if ! [[ -e JellyfinMediaPlayer.dmg ]]
39+
then
40+
echo "Failed to create dmg after 10 attempts"
41+
exit 1
42+
fi
3243
- name: Archive production artifacts
3344
uses: actions/upload-artifact@v4
3445
with:
@@ -56,7 +67,7 @@ jobs:
5667
python3 ./scripts/fix-webengine.py ./build/output/Jellyfin\ Media\ Player.app
5768
codesign --force --deep -s - ./build/output/Jellyfin\ Media\ Player.app/
5869
brew install create-dmg
59-
create-dmg --volname "Jellyfin Media Player" --no-internet-enable "JellyfinMediaPlayer.dmg" "./build/output/Jellyfin Media Player.app" || create-dmg --volname "Jellyfin Media Player" --no-internet-enable "JellyfinMediaPlayer.dmg" "./build/output/Jellyfin Media Player.app"
70+
create-dmg --volname "Jellyfin Media Player" --no-internet-enable "JellyfinMediaPlayer.dmg" "./build/output/Jellyfin Media Player.app"
6071
- name: Archive production artifacts
6172
uses: actions/upload-artifact@v4
6273
with:

0 commit comments

Comments
 (0)