diff options
author | Richard Maw <richard.maw@codethink.co.uk> | 2012-06-14 15:50:03 +0000 |
---|---|---|
committer | Richard Maw <richard.maw@codethink.co.uk> | 2012-06-14 15:50:03 +0000 |
commit | f33553534538be564461d57f81a63ffa4ca6fd54 (patch) | |
tree | e4ee5eddf112cbe1ee317b4e6c40248e95b33f6d /scripts | |
parent | 8762b87aad701e2f038bf2a0fc5016fd6a632c64 (diff) | |
download | morph-f33553534538be564461d57f81a63ffa4ca6fd54.tar.gz |
tests: fix missing baserock meta files
This adds the ability to do this to the script, and fixes use of
the script to add the new parameter.
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/assemble-stratum | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/scripts/assemble-stratum b/scripts/assemble-stratum index fa4a0390..1fe9bd12 100755 --- a/scripts/assemble-stratum +++ b/scripts/assemble-stratum @@ -39,6 +39,7 @@ class AssembleStratum(cliapp.Application): if self.settings['tarformat'] != "": tarformat += self.settings['tarformat'] outfile = tarfile.open(args[1], tarformat) + # concatenate chunk tarballs for chunk in chunklist: path = os.path.join(self.settings['cachedir'], 'artifacts', chunk) chunktar = tarfile.open(path, mode='r:*') @@ -48,6 +49,10 @@ class AssembleStratum(cliapp.Application): else: outfile.addfile(tarinfo) chunktar.close() + # add the stratum's metadata + if os.path.exists(args[0] + '.meta'): + outfile.add(args[0] + '.meta', + os.path.join('baserock', '%s.meta' % args[2])) outfile.close() AssembleStratum().run() |