Package the json manifest too

This commit is contained in:
Davide Cavalca 2023-07-20 08:31:18 -07:00
parent cdf0a1f24a
commit 340844f960
3 changed files with 43 additions and 35 deletions

2
.gitignore vendored
View File

@ -3,3 +3,5 @@ fedora.icns
installer_data.json installer_data.json
merged_installer_data.json merged_installer_data.json
fedora-*.zip fedora-*.zip
fedora-*.raw.zst
fedora-*.json

View File

@ -149,10 +149,12 @@ def packageUpload(target):
package = f"{base}.zip" package = f"{base}.zip"
logs_package = f"{base}-logs.zip" logs_package = f"{base}-logs.zip"
image = f"{base}.raw.zstd" image = f"{base}.raw.zstd"
manifest = f"{base}.json"
uploadToS3(package, f"os/{package}") uploadToS3(package, f"os/{package}")
uploadToS3(logs_package, f"os/{logs_package}") uploadToS3(logs_package, f"os/{logs_package}")
uploadToS3(image, f"os/{image}") uploadToS3(image, f"os/{image}")
uploadToS3(manifest, f"os/{manifest}")
def getManifest(): def getManifest():

View File

@ -65,9 +65,7 @@ pushd "${workdir}/package" > /dev/null
7z a -tzip -r "${basedir}/${package}" . 7z a -tzip -r "${basedir}/${package}" .
popd > /dev/null popd > /dev/null
cat > installer_data.json <<EOF cat > "${package}.json" <<EOF
{
"os_list": [
{ {
"name": "Fedora Linux ${pretty_release}", "name": "Fedora Linux ${pretty_release}",
"default_os_name": "Fedora Linux ${pretty_release}", "default_os_name": "Fedora Linux ${pretty_release}",
@ -102,6 +100,12 @@ cat > installer_data.json <<EOF
} }
] ]
} }
EOF
cat > installer_data.json <<EOF
{
"os_list": [
$(cat "${package}.json")
] ]
} }
EOF EOF