Skip to content

Commit 727e23b

Browse files
committed
ensure minor syncs regenerate all manifests
1 parent f29ae47 commit 727e23b

File tree

1 file changed

+17
-1
lines changed

1 file changed

+17
-1
lines changed

sync/minor-release-sync-to-staging.sh

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/bin/bash
22
# Performs a full on sync of a minor release, directories and all. It calls the
33
# other scripts in this directory to assist where necessary.
4-
# Note that this is EL8 specific
4+
# Note that this is EL8, EL10+ only
55
#
66
# Source common variables
77
# shellcheck disable=SC2046,1091,1090
@@ -41,10 +41,16 @@ for COMPOSE in "${NONSIG_COMPOSE[@]}"; do
4141
test -d "${x}/${ARCH}/iso" && rmdir "${x}/${ARCH}/iso"
4242
done
4343
pushd "isos/${ARCH}" || { echo "${ARCH}: Failed to change directory"; break; }
44+
4445
echo "Symlinking to 'latest' if ISO exists"
4546
test -f "Rocky-${REVISION}-${ARCH}-boot.iso" && ln -s "Rocky-${REVISION}-${ARCH}-boot.iso" "Rocky-${MAJ}-latest-${ARCH}-boot.iso"
4647
test -f "Rocky-${REVISION}-${ARCH}-dvd1.iso" && ln -s "Rocky-${REVISION}-${ARCH}-dvd1.iso" "Rocky-${MAJ}-latest-${ARCH}-dvd.iso"
4748
test -f "Rocky-${REVISION}-${ARCH}-minimal.iso" && ln -s "Rocky-${REVISION}-${ARCH}-minimal.iso" "Rocky-${MAJ}-latest-${ARCH}-minimal.iso"
49+
echo "(Re)generating manifests"
50+
for file in *.iso; do
51+
xorriso -dev "${file}" --find | tail -n+2 | tr -d "'" | cut -c2- | sort > "${file}.manifest"
52+
done
53+
4854
for file in *.iso; do
4955
printf "# %s: %s bytes\n%s\n" \
5056
"${file}" \
@@ -76,6 +82,16 @@ for COMPOSE in "${NONSIG_COMPOSE[@]}"; do
7682
popd || { echo "${COMPOSE}: Failed to change directory"; break; }
7783
done
7884

85+
# Sync images, they are NOT part of the normal compose at the moment.
86+
# mv everything from iso/* and images/* to base, rmdir
87+
# if vagrant is in the name, rename them to drop the ending
88+
# for x in $(ls) ; do if [[ "${x}" =~ "vagrant" ]]; then mv ${x} $(echo ${x} | sed 's/\.vagrant\..*\(\.box\)/\1/g') ; fi ; done
89+
# create symlinks for live sed -E "s/${MAJOR}\.${MINOR}/${MAJOR}/g ; s/[0-9]+\.[0-9]+/latest/g"
90+
# create symlinks for images for x in * ; do ln -s ${x} $(echo $x | sed -E 's/-10.0-[0-9]+\.[0-9]+/.latest/g ; s/\.oci//g') ; done
91+
# remove original CHECKSUM file and then checksum everything
92+
# cat all checksums into single files, sign it
93+
# we need a separate script that can do this same stuff and not kill everything
94+
7995
# Create symlinks for repos that were once separate from the main compose
8096
for LINK in "${!LINK_REPOS[@]}"; do
8197
ln -sr "${STAGING_ROOT}/${CATEGORY_STUB}/${REV}/${LINK}" \

0 commit comments

Comments
 (0)