lookaside: Add the hash type to the folder structure
This makes it more explicit which hash was used for a given tarball. https://fedorahosted.org/rel-eng/ticket/5846
This commit is contained in:
parent
a92efe252a
commit
1b2337558f
1 changed files with 5 additions and 1 deletions
|
@ -148,6 +148,10 @@ def main():
|
||||||
print >> sys.stderr, '[username=%s] Processing upload request: NAME=%s FILENAME=%s %sSUM=%s' % (username, name, filename, hash_type.upper(), checksum)
|
print >> sys.stderr, '[username=%s] Processing upload request: NAME=%s FILENAME=%s %sSUM=%s' % (username, name, filename, hash_type.upper(), checksum)
|
||||||
|
|
||||||
module_dir = os.path.join(CACHE_DIR, name)
|
module_dir = os.path.join(CACHE_DIR, name)
|
||||||
|
hash_dir = os.path.join(module_dir, filename, hash_type, checksum)
|
||||||
|
|
||||||
|
if hash_type == "md5":
|
||||||
|
# Preserve compatibility with the current folder hierarchy for md5
|
||||||
hash_dir = os.path.join(module_dir, filename, checksum)
|
hash_dir = os.path.join(module_dir, filename, checksum)
|
||||||
|
|
||||||
# first test if the module really exists
|
# first test if the module really exists
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue