From 20bf0812dbb5860bf4a1c2bace920a85e9c702fa Mon Sep 17 00:00:00 2001 From: Neil Hanlon Date: Mon, 11 Jul 2022 21:15:31 -0400 Subject: [PATCH] revert to stg url now that CDN is fixed. add in some additional metadata for builds and cleanup output for containers --- iso/empanadas/empanadas/scripts/build_image.py | 6 +++++- iso/empanadas/empanadas/templates/icicle/tdl.xml.tmpl | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/iso/empanadas/empanadas/scripts/build_image.py b/iso/empanadas/empanadas/scripts/build_image.py index b4a6c97..508f99c 100644 --- a/iso/empanadas/empanadas/scripts/build_image.py +++ b/iso/empanadas/empanadas/scripts/build_image.py @@ -96,7 +96,8 @@ class ImageBuild: # Yes, this is gross. I'll fix it later. if self.image_type in ["Container"]: self.stage_commands = [ - ["tar", "-C", f"{self.outdir}", "--strip-components=1", "-x", "-f", lambda: f"{STORAGE_DIR}/{self.target_uuid}.body", "*/layer.tar"] + ["tar", "-C", f"{self.outdir}", "--strip-components=1", "-x", "-f", lambda: f"{STORAGE_DIR}/{self.target_uuid}.body", "*/layer.tar"], + ["xz", f"{self.outdir}/layer.tar"] ] if self.image_type in ["GenericCloud"]: self.stage_commands = [ @@ -124,6 +125,9 @@ class ImageBuild: ] + if self.stage_commands: + self.stage_commands += ["cp", "-v", lambda: f"{STORAGE_DIR}/{self.target_uuid}.meta", f"{self.outdir}/build.meta"] + try: os.mkdir(self.outdir) except FileExistsError as e: diff --git a/iso/empanadas/empanadas/templates/icicle/tdl.xml.tmpl b/iso/empanadas/empanadas/templates/icicle/tdl.xml.tmpl index ad545f5..5ba9c6d 100644 --- a/iso/empanadas/empanadas/templates/icicle/tdl.xml.tmpl +++ b/iso/empanadas/empanadas/templates/icicle/tdl.xml.tmpl @@ -5,7 +5,7 @@ {{minor}} {{architecture}} - https://download.rockylinux.org/pub/rocky/{{major}}/BaseOS/{{architecture}}/{{installdir}} + https://download.rockylinux.org/stg/rocky/{{major}}/BaseOS/{{architecture}}/{{installdir}} rpm -qa --qf '%{NAME},%{VERSION},%{RELEASE},%{ARCH},%{EPOCH},%{SIZE},%{SIGMD5},%{BUILDTIME}\n'