Remove older update push scripts
Signed-off-by: Patrick Uiterwijk <patrick@puiterwijk.org>
This commit is contained in:
parent
03f7710d61
commit
390cec9bf5
2 changed files with 0 additions and 368 deletions
|
@ -1,111 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
SOURCE=/mnt/koji/mash/updates
|
|
||||||
DEST=/pub/epel
|
|
||||||
|
|
||||||
OPTIONS="-rlptDvHh --stats --delay-updates $RSYNC_OPTS"
|
|
||||||
|
|
||||||
for rel in 6; do
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --exclude "repodata/*" --exclude "headers/*" \
|
|
||||||
$SOURCE/dist-${rel}E-epel/ $DEST/${rel}/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay \
|
|
||||||
$SOURCE/dist-${rel}E-epel/ $DEST/${rel}/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"epel\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.epel.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --exclude "repodata/*" --exclude "headers/*" \
|
|
||||||
$SOURCE/dist-${rel}E-epel-testing/ $DEST/testing/${rel}/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay \
|
|
||||||
$SOURCE/dist-${rel}E-epel-testing/ $DEST/testing/${rel}/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"epel-testing\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.epel.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
for rel in 7; do
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --exclude "repodata/*" \
|
|
||||||
$SOURCE/epel${rel}/ $DEST/$rel/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay \
|
|
||||||
$SOURCE/epel${rel}/ $DEST/$rel/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"epel\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.epel.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --exclude "repodata/*" \
|
|
||||||
$SOURCE/epel${rel}-testing/ $DEST/testing/${rel}/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay \
|
|
||||||
$SOURCE/epel${rel}-testing/ $DEST/testing/${rel}/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"epel-testing\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.epel.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
for rel in 6 7; do
|
|
||||||
if [ ${rel} -eq 7 ]; then
|
|
||||||
TARGET_DIR=${DEST}/${rel}/x86_64/e
|
|
||||||
else
|
|
||||||
TARGET_DIR=${DEST}/${rel}/x86_64
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ -f ${TARGET_DIR}/epel-release*rpm ]; then
|
|
||||||
# We have a file to match. [This may sort wrong at -9 -> -10]
|
|
||||||
CANDIDATE=$( ls ${TARGET_DIR}/epel-release-*rpm | sort | tail -n 1)
|
|
||||||
TARGET=${DEST}/epel-release-latest-${rel}.noarch.rpm
|
|
||||||
# Does our symbolic link exist?
|
|
||||||
if [ -L ${TARGET} ]; then
|
|
||||||
# check to see if the link matches the candidate
|
|
||||||
TEST=$( readlink -e ${TARGET} )
|
|
||||||
if [ "${TEST}" != "${CANDIDATE}" ]; then
|
|
||||||
ln -sf $(echo ${CANDIDATE}|sed -e "s|$DEST|./|g" -e 's|//|/|g') ${TARGET}
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
# first time for everything.
|
|
||||||
ln -sf $(echo ${CANDIDATE}|sed -e "s|$DEST|./|g" -e 's|//|/|g') ${TARGET}
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
echo "No target file for epel-release ${rel} to link against."
|
|
||||||
fi
|
|
||||||
done
|
|
|
@ -1,257 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
SOURCE=/mnt/koji/mash/updates
|
|
||||||
DEST=/pub/fedora/linux/updates/
|
|
||||||
ALTDEST=/pub/fedora-secondary/updates/
|
|
||||||
ATOMICSOURCE=/mnt/koji/mash/atomic/
|
|
||||||
ATOMICDEST=/mnt/koji/atomic/
|
|
||||||
|
|
||||||
OPTIONS="-rlptDvHh --stats --delay-updates $RSYNC_OPTS"
|
|
||||||
#f26 exlcude
|
|
||||||
PRIMARY_EXCLUDES_26=" --exclude=aarch64 --exclude=i386 --exclude=ppc64 --exclude=ppc64le --exclude=s390x "
|
|
||||||
ALT_EXCLUDES_26=" --exclude=armhfp --exclude=SRPMS --exclude=x86_64 --exclude=s390x"
|
|
||||||
|
|
||||||
#f27 and above exlcudes
|
|
||||||
PRIMARY_EXCLUDES=" --exclude=aarch64 --exclude=i386 --exclude=ppc64 --exclude=ppc64le --exclude=s390x "
|
|
||||||
ALT_EXCLUDES=" --exclude=armhfp --exclude=SRPMS --exclude=x86_64 "
|
|
||||||
|
|
||||||
#old style simple sync
|
|
||||||
for rel in 25; do
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --exclude "repodata/*" \
|
|
||||||
$SOURCE/f$rel-updates/ $DEST/$rel/ --link-dest $DEST/testing/$rel/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay --exclude=Live --exclude=Images \
|
|
||||||
$SOURCE/f$rel-updates/ $DEST/$rel/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"updates\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.fedora.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
|
|
||||||
done
|
|
||||||
for rel in 25; do
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --exclude "repodata/*" \
|
|
||||||
$SOURCE/f$rel-updates-testing/ $DEST/testing/$rel/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay --exclude=Live --exclude=Images \
|
|
||||||
$SOURCE/f$rel-updates-testing/ $DEST/testing/$rel/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"updates-testing\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.fedora.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
|
|
||||||
done
|
|
||||||
#new style primary sync
|
|
||||||
for rel in 26; do
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --exclude "repodata/*" $PRIMARY_EXCLUDES_26 \
|
|
||||||
$SOURCE/f$rel-updates/ $DEST/$rel/ --link-dest $DEST/testing/$rel/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay $PRIMARY_EXCLUDES_26 --exclude=Live --exclude=Images \
|
|
||||||
$SOURCE/f$rel-updates/ $DEST/$rel/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"updates\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.fedora.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
|
|
||||||
done
|
|
||||||
for rel in 26; do
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --exclude "repodata/*" $PRIMARY_EXCLUDES_26 \
|
|
||||||
$SOURCE/f$rel-updates-testing/ $DEST/testing/$rel/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay $PRIMARY_EXCLUDES_26 --exclude=Live --exclude=Images \
|
|
||||||
$SOURCE/f$rel-updates-testing/ $DEST/testing/$rel/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"updates-testing\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.fedora.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
|
|
||||||
done
|
|
||||||
# new style alternative sync
|
|
||||||
for rel in 26; do
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --exclude "repodata/*" $ALT_EXCLUDES_26 \
|
|
||||||
$SOURCE/f$rel-updates/ $ALTDEST/$rel/ --link-dest $ALTDEST/testing/$rel/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay $ALT_EXCLUDES_26 --exclude=Live --exclude=Images \
|
|
||||||
$SOURCE/f$rel-updates/ $ALTDEST/$rel/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"updates\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.fedora.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
|
|
||||||
done
|
|
||||||
for rel in 26; do
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --exclude "repodata/*" $ALT_EXCLUDES_26 \
|
|
||||||
$SOURCE/f$rel-updates-testing/ $ALTDEST/testing/$rel/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay $ALT_EXCLUDES_26 --exclude=Live --exclude=Images \
|
|
||||||
$SOURCE/f$rel-updates-testing/ $ALTDEST/testing/$rel/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"updates-testing\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.fedora.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
|
|
||||||
done
|
|
||||||
|
|
||||||
#new style primary sync for f27 and above
|
|
||||||
for rel in 27; do
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --exclude "repodata/*" $PRIMARY_EXCLUDES \
|
|
||||||
$SOURCE/f$rel-updates/ $DEST/$rel/ --link-dest $DEST/testing/$rel/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay $PRIMARY_EXCLUDES --exclude=Live --exclude=Images \
|
|
||||||
$SOURCE/f$rel-updates/ $DEST/$rel/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"updates\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.fedora.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
|
|
||||||
done
|
|
||||||
for rel in 27; do
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --exclude "repodata/*" $PRIMARY_EXCLUDES \
|
|
||||||
$SOURCE/f$rel-updates-testing/ $DEST/testing/$rel/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay $PRIMARY_EXCLUDES --exclude=Live --exclude=Images \
|
|
||||||
$SOURCE/f$rel-updates-testing/ $DEST/testing/$rel/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"updates-testing\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.fedora.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
|
|
||||||
done
|
|
||||||
# new style alternative sync for f27 and above
|
|
||||||
for rel in 27; do
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --exclude "repodata/*" $ALT_EXCLUDES \
|
|
||||||
$SOURCE/f$rel-updates/ $ALTDEST/$rel/ --link-dest $ALTDEST/testing/$rel/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay $ALT_EXCLUDES --exclude=Live --exclude=Images \
|
|
||||||
$SOURCE/f$rel-updates/ $ALTDEST/$rel/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"updates\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.fedora.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
|
|
||||||
done
|
|
||||||
for rel in 27; do
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --exclude "repodata/*" $ALT_EXCLUDES \
|
|
||||||
$SOURCE/f$rel-updates-testing/ $ALTDEST/testing/$rel/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay $ALT_EXCLUDES --exclude=Live --exclude=Images \
|
|
||||||
$SOURCE/f$rel-updates-testing/ $ALTDEST/testing/$rel/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"updates-testing\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.fedora.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
|
|
||||||
done
|
|
||||||
|
|
||||||
for rel in 25 26; do
|
|
||||||
|
|
||||||
OUTPUT1=$(rsync $OPTIONS --ignore-existing \
|
|
||||||
$ATOMICSOURCE/$rel/objects/ $ATOMICDEST/$rel/objects/)
|
|
||||||
OUTPUT2=$(rsync $OPTIONS --delete --delete-delay --exclude=objects/ \
|
|
||||||
$ATOMICSOURCE/$rel/ $ATOMICDEST/$rel/)
|
|
||||||
|
|
||||||
# Grep out some signals from the stats
|
|
||||||
bytes=$(echo "$OUTPUT1" | grep "Literal data" | awk ' { print $3 } ')
|
|
||||||
deleted=$(echo "$OUTPUT2" | grep "deleting " | wc -l)
|
|
||||||
|
|
||||||
# If anything changed, then publish a fedmsg message as bodhi.updates.sync
|
|
||||||
if [ "$bytes" != "0" -o "$deleted" != "0" ]; then
|
|
||||||
echo "{\"bytes\": \"$bytes\", \"deleted\": \"$deleted\", \"repo\": \"atomic\", \"release\": \"$rel\"}" | fedmsg-logger \
|
|
||||||
--cert-prefix ftpsync \
|
|
||||||
--modname bodhi \
|
|
||||||
--topic updates.fedora.sync \
|
|
||||||
--json-input &> /dev/null
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
# Sync out the rpm-ostree logs
|
|
||||||
rsync $OPTIONS /srv/fedora-atomic/logs/ /mnt/koji/mash/atomic-updates-logs/ &> /dev/null
|
|
Loading…
Add table
Add a link
Reference in a new issue