diff --git a/roles/bodhi2/backend/files/update-fullfilelist b/roles/bodhi2/backend/files/update-fullfilelist index 0302c6a5b6..bac3f9c909 100755 --- a/roles/bodhi2/backend/files/update-fullfilelist +++ b/roles/bodhi2/backend/files/update-fullfilelist @@ -1,6 +1,6 @@ #!/bin/bash -# currently runs on releng2.fedora.phx.redhat.com +# currently runs on bodhi-backend01 after updates pushes MOD=$1 [ -z "$MOD" ] && { @@ -8,6 +8,8 @@ MOD=$1 exit 1 } +# This is the old traditional fullfilelist with no timestamps + TMPFILE=$(mktemp -p /tmp/) pushd /pub/$MOD > /dev/null find * -print > $TMPFILE @@ -18,3 +20,16 @@ else fi chmod 0644 fullfilelist popd > /dev/null + +# This is the new list with timestamps + +TMPFILE=$(mktemp -p /tmp/) +pushd /pub/$MOD > /dev/null +/usr/bin/rsync --no-h --list-only -r . > $TMPFILE +if diff $TMPFILE fullfiletimelist > /dev/null; then + rm -f $TMPFILE +else + mv $TMPFILE fullfiletimelist +fi +chmod 0644 fullfiletimelist +popd > /dev/null diff --git a/roles/releng/files/update-fullfilelist b/roles/releng/files/update-fullfilelist index 0302c6a5b6..bac3f9c909 100755 --- a/roles/releng/files/update-fullfilelist +++ b/roles/releng/files/update-fullfilelist @@ -1,6 +1,6 @@ #!/bin/bash -# currently runs on releng2.fedora.phx.redhat.com +# currently runs on bodhi-backend01 after updates pushes MOD=$1 [ -z "$MOD" ] && { @@ -8,6 +8,8 @@ MOD=$1 exit 1 } +# This is the old traditional fullfilelist with no timestamps + TMPFILE=$(mktemp -p /tmp/) pushd /pub/$MOD > /dev/null find * -print > $TMPFILE @@ -18,3 +20,16 @@ else fi chmod 0644 fullfilelist popd > /dev/null + +# This is the new list with timestamps + +TMPFILE=$(mktemp -p /tmp/) +pushd /pub/$MOD > /dev/null +/usr/bin/rsync --no-h --list-only -r . > $TMPFILE +if diff $TMPFILE fullfiletimelist > /dev/null; then + rm -f $TMPFILE +else + mv $TMPFILE fullfiletimelist +fi +chmod 0644 fullfiletimelist +popd > /dev/null