Skip to content

Commit

Permalink
Retry docker image push on failure
Browse files Browse the repository at this point in the history
  • Loading branch information
reconman committed Nov 9, 2021
1 parent b863286 commit 84c5d6c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,9 @@ jobs:
sudo ctr i import --base-name ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} --digests --all-platforms /tmp/plexanisync-image.tar
while IFS= read -r line; do
echo "Pushing $line"
sudo ctr i push --user "${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}" $line
for i in {1..5}; do
sudo ctr i push --user "${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}" $line && break || sleep 15;
done
done <<< "${{ steps.meta.outputs.tags }}"
build-docker-tautulli:
Expand Down Expand Up @@ -130,5 +132,7 @@ jobs:
sudo ctr i import --base-name ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} --digests --all-platforms /tmp/tautulli-image.tar
while IFS= read -r line; do
echo "Pushing $line"
sudo ctr i push --user "${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}" $line
for i in {1..5}; do
sudo ctr i push --user "${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}" $line && break || sleep 15;
done
done <<< "${{ steps.meta.outputs.tags }}"
8 changes: 3 additions & 5 deletions Docker/PlexAniSync/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,16 @@ ENV PLEX_SECTION=Anime \
PLEX_TOKEN='' \
ANI_USERNAME='' \
ANI_TOKEN='' \
INTERVAL=3600

ENV PATH="${PATH}:~/.local/bin"
INTERVAL=3600 \
PATH="${PATH}:~/.local/bin"

ADD ./* /plexanisync/
ADD Docker/PlexAniSync/run/* /plexanisync/

RUN cd /plexanisync && \
python3 -m pip install -r requirements.txt && \
cd ..

ADD Docker/PlexAniSync/run/* /plexanisync/

LABEL org.opencontainers.image.documentation=https://github.com/RickDB/PlexAniSync/blob/master/Docker/PlexAniSync/README.md

CMD ["/plexanisync/runsync.sh"]

0 comments on commit 84c5d6c

Please sign in to comment.