Commit graph

4 commits

Author SHA1 Message Date
Mathieu Bridon
af02e32085 distgit: Ensure the hardlinked sources all belong to apache
Without this, client uploads and downloads aren't working any more.
2015-07-15 17:20:35 +02:00
Mathieu Bridon
3ff24f67b2 distgit: Generators don't have a length
This is fallout from the previous commit.
2015-07-13 23:03:44 +02:00
Mathieu Bridon
a11c53cb4d distgit: Harden the hardlink script a bit
Turns out the lookaside cache is not as clean as I expected.

Specifically, it contains some files where we'd expect directories, for
example:

/srv/cache/lookaside/pkgs/GFS-kernel/@13013.1e77f453ba1c86cd7616087d0643bbd8e
/srv/cache/lookaside/pkgs/openswan/tmpLRV5Gn5556cb2fcea6ba862ce14e1debf98b6d

This commit makes the script print an error instead of crashing on an
OSError in such a case.
2015-07-13 22:55:57 +02:00
Mathieu Bridon
e7074e8ad9 distgit: Add a script to make the new paths in the lookaside cache
We are migrating from the following path scheme:
    /%(srpmname)s/%(filename)s/%(hash)s/%(filename)s

To:
    /%(srpmname)s/%(filename)s/%(hashtype)s/%(hash)s/%(filename)s

As a result, we need to hardlink all the files existing under the old
path to their new path.

This script does just that.

Given that it should only ever be run once anyway, it is added as a
file to the distgit role, but not set to be installed anywhere.
2015-07-13 20:16:30 +00:00