s3-mirror: delay the sync --delete
a bit
So the running DNF processes can finish transaction.
This commit is contained in:
parent
164bd1e7a9
commit
33f2be7c65
1 changed files with 7 additions and 1 deletions
|
@ -119,7 +119,6 @@ done
|
||||||
for file in $(echo /srv/pub/epel/8/*/repodata/repomd.xml | sed 's#/srv##g'); do
|
for file in $(echo /srv/pub/epel/8/*/repodata/repomd.xml | sed 's#/srv##g'); do
|
||||||
aws cloudfront create-invalidation --distribution-id "$DIST_ID" --paths "$file"
|
aws cloudfront create-invalidation --distribution-id "$DIST_ID" --paths "$file"
|
||||||
done
|
done
|
||||||
"${CMD3[@]}" /srv/pub/epel/ "s3://$S3_MIRROR/pub/epel/"
|
|
||||||
|
|
||||||
# Sync Fedora
|
# Sync Fedora
|
||||||
#echo $CMD /srv/pub/fedora/ s3://$S3_MIRROR/pub/fedora/
|
#echo $CMD /srv/pub/fedora/ s3://$S3_MIRROR/pub/fedora/
|
||||||
|
@ -131,4 +130,11 @@ echo "Ending Fedora sync at $(date)" >> /var/log/s3-mirror/timestamps
|
||||||
for file in $(echo /srv/pub/fedora/linux/updates/*/*/*/repodata/repomd.xml | sed 's#/srv##g'); do
|
for file in $(echo /srv/pub/fedora/linux/updates/*/*/*/repodata/repomd.xml | sed 's#/srv##g'); do
|
||||||
aws cloudfront create-invalidation --distribution-id "$DIST_ID" --paths "$file"
|
aws cloudfront create-invalidation --distribution-id "$DIST_ID" --paths "$file"
|
||||||
done
|
done
|
||||||
|
|
||||||
|
# Consider some DNF processes started downloading metadata before we invalidated
|
||||||
|
# caches, and started with outdated repomd.xml file. Give it 10 minutes so they
|
||||||
|
# have chance to download the rest of metadata and RPMs.
|
||||||
|
sleep 600
|
||||||
|
|
||||||
|
"${CMD3[@]}" /srv/pub/epel/ "s3://$S3_MIRROR/pub/epel/"
|
||||||
"${CMD3[@]}" /srv/pub/fedora/ s3://$S3_MIRROR/pub/fedora/
|
"${CMD3[@]}" /srv/pub/fedora/ s3://$S3_MIRROR/pub/fedora/
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue