pungi-fedora/nightly.sh

216 lines
9.3 KiB
Bash
Raw Normal View History

#!/bin/sh
export LC_ALL=C
CONFIG="fedora.conf"
TARGET_DIR="/mnt/koji/compose/rawhide"
#OLD_COMPOSES_DIR="--old-composes=/mnt/fedora_koji/compose/f23 --old-composes=$TARGET_DIR"
NIGHTLY="--nightly"
SKIP_PHASES="--skip-phase=productimg"
DEST=$(pwd)
DATE=$(date "+%Y%m%d")
nightly: include shortname in fedmsgs, clean up version vars The main point here is to include the compose 'shortname' in compose fedmsgs, as #484 does for post-release compose types. While doing this I noticed there's rather a lot of mess and cruft in the various version-related variables here (and a few others). `GIT_BRANCH` variable is never used anywhere any more, so it's removed. `BRANCH` was never used anywhere, so it is gone. (It appears to have been added in a25b08c7 but never used). There seemed to be no useful distinction between `DIST` and `BRANCHED`, and both actually seem to be used mainly to specify a release version. The exception is that `BRANCHED` was set to "Modular-Bikeshed" in nightly-modular.sh , but there is no justification for this that I can find, and its only practical use was as the value of the `branch` key in fedmsgs. So far as I can figure out, the original purpose of the `branch` key was for when we sent out `compose.branched.(foo)` fedmsgs - it was e.g. 'f18' when Branched was Fedora 18. As we now don't send out `compose.branched` messages any more, but include the release number in the message topic for Branched messages (e.g. `compose.27`), this purpose no longer applies. So the key just doesn't seem to have any particular use at all any more, and I don't think changing its value will have any real consequences. Thus, `BRANCH`, `BRANCHED` and `DIST` are replaced by `RELEASE` and `RELEASE_TITLE`, which specify the release version. Their values will be identical for numerical release versions, but for Rawhide and Bikeshed we need to know both the lower-case and title-case versions of the name; RELEASE_TITLE is the title-case version. We use `$SHORT-$RELEASE_TITLE` to replace several instances of hardcoding in the scripts (e.g. Fedora-Modular-Bikeshed). The `ATOMIC`, `ATOMICREPO` and `ATOMICDEST` variables that were blindly copied from nightly.sh to nightly-modular.sh, but never actually used in it, are also removed. Signed-off-by: Adam Williamson <awilliam@redhat.com>
2017-12-05 01:24:43 +00:00
SHORT="Fedora"
RELEASE="rawhide"
RELEASE_TITLE="Rawhide"
COMPSFILE="comps-rawhide.xml"
nightly: include shortname in fedmsgs, clean up version vars The main point here is to include the compose 'shortname' in compose fedmsgs, as #484 does for post-release compose types. While doing this I noticed there's rather a lot of mess and cruft in the various version-related variables here (and a few others). `GIT_BRANCH` variable is never used anywhere any more, so it's removed. `BRANCH` was never used anywhere, so it is gone. (It appears to have been added in a25b08c7 but never used). There seemed to be no useful distinction between `DIST` and `BRANCHED`, and both actually seem to be used mainly to specify a release version. The exception is that `BRANCHED` was set to "Modular-Bikeshed" in nightly-modular.sh , but there is no justification for this that I can find, and its only practical use was as the value of the `branch` key in fedmsgs. So far as I can figure out, the original purpose of the `branch` key was for when we sent out `compose.branched.(foo)` fedmsgs - it was e.g. 'f18' when Branched was Fedora 18. As we now don't send out `compose.branched` messages any more, but include the release number in the message topic for Branched messages (e.g. `compose.27`), this purpose no longer applies. So the key just doesn't seem to have any particular use at all any more, and I don't think changing its value will have any real consequences. Thus, `BRANCH`, `BRANCHED` and `DIST` are replaced by `RELEASE` and `RELEASE_TITLE`, which specify the release version. Their values will be identical for numerical release versions, but for Rawhide and Bikeshed we need to know both the lower-case and title-case versions of the name; RELEASE_TITLE is the title-case version. We use `$SHORT-$RELEASE_TITLE` to replace several instances of hardcoding in the scripts (e.g. Fedora-Modular-Bikeshed). The `ATOMIC`, `ATOMICREPO` and `ATOMICDEST` variables that were blindly copied from nightly.sh to nightly-modular.sh, but never actually used in it, are also removed. Signed-off-by: Adam Williamson <awilliam@redhat.com>
2017-12-05 01:24:43 +00:00
TMPDIR=`mktemp -d /tmp/$RELEASE.$DATE.XXXX`
TOMAIL="devel@lists.fedoraproject.org test@lists.fedoraproject.org"
FROM="Fedora Rawhide Report <rawhide@fedoraproject.org>"
RSYNCPREFIX="sudo -u ftpsync"
RSYNCTARGET="/pub/fedora/linux/development/$RELEASE"
RSYNCALTTARGET="/pub/alt/development/$RELEASE"
RSYNCSECTARGET="/pub/fedora-secondary/development/$RELEASE"
ATOMICSRCREPO="/mnt/koji/compose/atomic/repo/"
ATOMICDESTREPO="/mnt/koji/atomic/repo/"
nightly: include shortname in fedmsgs, clean up version vars The main point here is to include the compose 'shortname' in compose fedmsgs, as #484 does for post-release compose types. While doing this I noticed there's rather a lot of mess and cruft in the various version-related variables here (and a few others). `GIT_BRANCH` variable is never used anywhere any more, so it's removed. `BRANCH` was never used anywhere, so it is gone. (It appears to have been added in a25b08c7 but never used). There seemed to be no useful distinction between `DIST` and `BRANCHED`, and both actually seem to be used mainly to specify a release version. The exception is that `BRANCHED` was set to "Modular-Bikeshed" in nightly-modular.sh , but there is no justification for this that I can find, and its only practical use was as the value of the `branch` key in fedmsgs. So far as I can figure out, the original purpose of the `branch` key was for when we sent out `compose.branched.(foo)` fedmsgs - it was e.g. 'f18' when Branched was Fedora 18. As we now don't send out `compose.branched` messages any more, but include the release number in the message topic for Branched messages (e.g. `compose.27`), this purpose no longer applies. So the key just doesn't seem to have any particular use at all any more, and I don't think changing its value will have any real consequences. Thus, `BRANCH`, `BRANCHED` and `DIST` are replaced by `RELEASE` and `RELEASE_TITLE`, which specify the release version. Their values will be identical for numerical release versions, but for Rawhide and Bikeshed we need to know both the lower-case and title-case versions of the name; RELEASE_TITLE is the title-case version. We use `$SHORT-$RELEASE_TITLE` to replace several instances of hardcoding in the scripts (e.g. Fedora-Modular-Bikeshed). The `ATOMIC`, `ATOMICREPO` and `ATOMICDEST` variables that were blindly copied from nightly.sh to nightly-modular.sh, but never actually used in it, are also removed. Signed-off-by: Adam Williamson <awilliam@redhat.com>
2017-12-05 01:24:43 +00:00
OLDCOMPOSE_ID=$(cat $TARGET_DIR/latest-$SHORT-$RELEASE_TITLE/COMPOSE_ID)
# uncomment and edit for resuming a failed compose
#COMPOSE_ID="Fedora-23-20150530.n.0"
# assume a releng dir is a git checkout of the releng repo
# if it does not exist clone it
if [ -d releng ]; then
pushd releng
git pull --rebase
popd
else
git clone https://pagure.io/releng.git
fi
# Set up our fedmsg function, using the releng repo definition
FEDMSG_MODNAME="compose"
FEDMSG_CERTPREFIX="releng"
. ./releng/scripts/fedmsg-functions.sh
# Announce that we are starting, even though we don't know the compose_id yet..
nightly: include shortname in fedmsgs, clean up version vars The main point here is to include the compose 'shortname' in compose fedmsgs, as #484 does for post-release compose types. While doing this I noticed there's rather a lot of mess and cruft in the various version-related variables here (and a few others). `GIT_BRANCH` variable is never used anywhere any more, so it's removed. `BRANCH` was never used anywhere, so it is gone. (It appears to have been added in a25b08c7 but never used). There seemed to be no useful distinction between `DIST` and `BRANCHED`, and both actually seem to be used mainly to specify a release version. The exception is that `BRANCHED` was set to "Modular-Bikeshed" in nightly-modular.sh , but there is no justification for this that I can find, and its only practical use was as the value of the `branch` key in fedmsgs. So far as I can figure out, the original purpose of the `branch` key was for when we sent out `compose.branched.(foo)` fedmsgs - it was e.g. 'f18' when Branched was Fedora 18. As we now don't send out `compose.branched` messages any more, but include the release number in the message topic for Branched messages (e.g. `compose.27`), this purpose no longer applies. So the key just doesn't seem to have any particular use at all any more, and I don't think changing its value will have any real consequences. Thus, `BRANCH`, `BRANCHED` and `DIST` are replaced by `RELEASE` and `RELEASE_TITLE`, which specify the release version. Their values will be identical for numerical release versions, but for Rawhide and Bikeshed we need to know both the lower-case and title-case versions of the name; RELEASE_TITLE is the title-case version. We use `$SHORT-$RELEASE_TITLE` to replace several instances of hardcoding in the scripts (e.g. Fedora-Modular-Bikeshed). The `ATOMIC`, `ATOMICREPO` and `ATOMICDEST` variables that were blindly copied from nightly.sh to nightly-modular.sh, but never actually used in it, are also removed. Signed-off-by: Adam Williamson <awilliam@redhat.com>
2017-12-05 01:24:43 +00:00
fedmsg_json_start=$(printf '{"log": "start", "branch": "%s", "arch": "%s", "short": "%s"}' "$RELEASE" "$ARCH" "$SHORT")
send_fedmsg "${fedmsg_json_start}" ${RELEASE} start
#pushd $TMPDIR
#git clone https://pagure.io/fedora-comps.git && {
# pushd fedora-comps
# make "${COMPSFILE}"
# cp "${COMPSFILE}" $DEST/
# popd
#}
#popd
./releng/scripts/block_retired.py --profile compose_koji
./releng/scripts/block_retired.py --profile compose_koji --namespace=container
CMD="pungi-koji --notification-script=/usr/bin/pungi-fedmsg-notification --notification-script=pungi-wait-for-signed-ostree-handler --config=$CONFIG --old-composes=$TARGET_DIR $OLD_COMPOSES_DIR $NIGHTLY $SKIP_PHASES"
if [ -z "$COMPOSE_ID" ]; then
CMD="$CMD --target-dir=$TARGET_DIR"
else
CMD="$CMD --debug-mode --compose-dir=$TARGET_DIR/$COMPOSE_ID"
fi
time $CMD "$@"
if [ "$?" != "0" ]; then
exit 1
fi
nightly: include shortname in fedmsgs, clean up version vars The main point here is to include the compose 'shortname' in compose fedmsgs, as #484 does for post-release compose types. While doing this I noticed there's rather a lot of mess and cruft in the various version-related variables here (and a few others). `GIT_BRANCH` variable is never used anywhere any more, so it's removed. `BRANCH` was never used anywhere, so it is gone. (It appears to have been added in a25b08c7 but never used). There seemed to be no useful distinction between `DIST` and `BRANCHED`, and both actually seem to be used mainly to specify a release version. The exception is that `BRANCHED` was set to "Modular-Bikeshed" in nightly-modular.sh , but there is no justification for this that I can find, and its only practical use was as the value of the `branch` key in fedmsgs. So far as I can figure out, the original purpose of the `branch` key was for when we sent out `compose.branched.(foo)` fedmsgs - it was e.g. 'f18' when Branched was Fedora 18. As we now don't send out `compose.branched` messages any more, but include the release number in the message topic for Branched messages (e.g. `compose.27`), this purpose no longer applies. So the key just doesn't seem to have any particular use at all any more, and I don't think changing its value will have any real consequences. Thus, `BRANCH`, `BRANCHED` and `DIST` are replaced by `RELEASE` and `RELEASE_TITLE`, which specify the release version. Their values will be identical for numerical release versions, but for Rawhide and Bikeshed we need to know both the lower-case and title-case versions of the name; RELEASE_TITLE is the title-case version. We use `$SHORT-$RELEASE_TITLE` to replace several instances of hardcoding in the scripts (e.g. Fedora-Modular-Bikeshed). The `ATOMIC`, `ATOMICREPO` and `ATOMICDEST` variables that were blindly copied from nightly.sh to nightly-modular.sh, but never actually used in it, are also removed. Signed-off-by: Adam Williamson <awilliam@redhat.com>
2017-12-05 01:24:43 +00:00
NEWCOMPOSE_ID=$(cat $TARGET_DIR/latest-$SHORT-$RELEASE_TITLE/COMPOSE_ID)
SHORTCOMPOSE_ID=$(echo $NEWCOMPOSE_ID|sed -e 's|Fedora-.*-||g')
# Set this to use later for a few items include depcheck
DESTDIR=$TARGET_DIR/$NEWCOMPOSE_ID
# Public URLs the synced compose will wind up at, we put them in fedmsgs
LOCATION="https://dl.fedoraproject.org$RSYNCTARGET"
ALT_LOCATION="https://dl.fedoraproject.org$RSYNCALTTARGET"
SECONDARY_LOCATION="https://dl.fedoraproject.org$RSYNCSECTARGET"
# Update fedmsg template
fedmsg_json_start=$(printf '{"log": "start", "branch": "%s", "arch": "%s", "short": "%s", "compose_id": "%s", "location": "%s", "alt_location": "%s", "secondary_location": "%s"}' "$RELEASE" "$ARCH" "$SHORT" "$NEWCOMPOSE_ID", "$LOCATION", "$ALT_LOCATION", "$SECONDARY_LOCATION")
fedmsg_json_done=$(printf '{"log": "done", "branch": "%s", "arch": "%s", "short": "%s", "compose_id": "%s", "location": "%s", "alt_location": "%s", "secondary_location": "%s"}' "$RELEASE" "$ARCH" "$SHORT" "$NEWCOMPOSE_ID", "$LOCATION", "$ALT_LOCATION", "$SECONDARY_LOCATION")
# Fix permissions on the grub efi files and fonts (they're 0600)
chmod -R go+r $DESTDIR/compose/*/*/os/EFI/
if ! compose-changelog -p "$DESTDIR/logs/" "$TARGET_DIR/$OLDCOMPOSE_ID/" "$DESTDIR/" 2>"$DESTDIR/logs/changelog.stderr"; then
# Generating changelog failed. We should not send an empty announcement to
# general public.
TOMAIL=""
VERSION="$(rpm -q compose-utils)"
# Instead report it to rel-eng@ list.
mutt -e "set from=\"$FROM\"" \
-e 'set envelope_from=yes' \
-s "Generating changelog for $NEWCOMPOSE_ID failed (with $VERSION)" \
rel-eng@lists.fedoraproject.org \
< "$DESTDIR/changelog.stderr"
fi
# Figure out a version for broken deps e-mail that goes to package maintainers.
# In Rawhide it's just rawhide, for branched versions we prepend F- to the number.
nightly: include shortname in fedmsgs, clean up version vars The main point here is to include the compose 'shortname' in compose fedmsgs, as #484 does for post-release compose types. While doing this I noticed there's rather a lot of mess and cruft in the various version-related variables here (and a few others). `GIT_BRANCH` variable is never used anywhere any more, so it's removed. `BRANCH` was never used anywhere, so it is gone. (It appears to have been added in a25b08c7 but never used). There seemed to be no useful distinction between `DIST` and `BRANCHED`, and both actually seem to be used mainly to specify a release version. The exception is that `BRANCHED` was set to "Modular-Bikeshed" in nightly-modular.sh , but there is no justification for this that I can find, and its only practical use was as the value of the `branch` key in fedmsgs. So far as I can figure out, the original purpose of the `branch` key was for when we sent out `compose.branched.(foo)` fedmsgs - it was e.g. 'f18' when Branched was Fedora 18. As we now don't send out `compose.branched` messages any more, but include the release number in the message topic for Branched messages (e.g. `compose.27`), this purpose no longer applies. So the key just doesn't seem to have any particular use at all any more, and I don't think changing its value will have any real consequences. Thus, `BRANCH`, `BRANCHED` and `DIST` are replaced by `RELEASE` and `RELEASE_TITLE`, which specify the release version. Their values will be identical for numerical release versions, but for Rawhide and Bikeshed we need to know both the lower-case and title-case versions of the name; RELEASE_TITLE is the title-case version. We use `$SHORT-$RELEASE_TITLE` to replace several instances of hardcoding in the scripts (e.g. Fedora-Modular-Bikeshed). The `ATOMIC`, `ATOMICREPO` and `ATOMICDEST` variables that were blindly copied from nightly.sh to nightly-modular.sh, but never actually used in it, are also removed. Signed-off-by: Adam Williamson <awilliam@redhat.com>
2017-12-05 01:24:43 +00:00
if [ "$RELEASE" = "rawhide" ]; then
TREENAME="$RELEASE"
else
nightly: include shortname in fedmsgs, clean up version vars The main point here is to include the compose 'shortname' in compose fedmsgs, as #484 does for post-release compose types. While doing this I noticed there's rather a lot of mess and cruft in the various version-related variables here (and a few others). `GIT_BRANCH` variable is never used anywhere any more, so it's removed. `BRANCH` was never used anywhere, so it is gone. (It appears to have been added in a25b08c7 but never used). There seemed to be no useful distinction between `DIST` and `BRANCHED`, and both actually seem to be used mainly to specify a release version. The exception is that `BRANCHED` was set to "Modular-Bikeshed" in nightly-modular.sh , but there is no justification for this that I can find, and its only practical use was as the value of the `branch` key in fedmsgs. So far as I can figure out, the original purpose of the `branch` key was for when we sent out `compose.branched.(foo)` fedmsgs - it was e.g. 'f18' when Branched was Fedora 18. As we now don't send out `compose.branched` messages any more, but include the release number in the message topic for Branched messages (e.g. `compose.27`), this purpose no longer applies. So the key just doesn't seem to have any particular use at all any more, and I don't think changing its value will have any real consequences. Thus, `BRANCH`, `BRANCHED` and `DIST` are replaced by `RELEASE` and `RELEASE_TITLE`, which specify the release version. Their values will be identical for numerical release versions, but for Rawhide and Bikeshed we need to know both the lower-case and title-case versions of the name; RELEASE_TITLE is the title-case version. We use `$SHORT-$RELEASE_TITLE` to replace several instances of hardcoding in the scripts (e.g. Fedora-Modular-Bikeshed). The `ATOMIC`, `ATOMICREPO` and `ATOMICDEST` variables that were blindly copied from nightly.sh to nightly-modular.sh, but never actually used in it, are also removed. Signed-off-by: Adam Williamson <awilliam@redhat.com>
2017-12-05 01:24:43 +00:00
TREENAME="F-$RELEASE"
fi
# disable sending email for now as spam-o-matic does not understand Rich dependencies
/usr/share/mash/spam-o-matic --nomail --treename="$TREENAME" "$DESTDIR/compose/Everything/" >"$DESTDIR/logs/depcheck"
[ -z "$ARCH" ] && {
./releng/scripts/critpath.py --url file://$DESTDIR/compose/Everything/ -o $DESTDIR/logs/critpath.txt rawhide &> $DESTDIR/logs/critpath.log
}
# Tell interested persons that the rsync is starting (zomg!)
nightly: include shortname in fedmsgs, clean up version vars The main point here is to include the compose 'shortname' in compose fedmsgs, as #484 does for post-release compose types. While doing this I noticed there's rather a lot of mess and cruft in the various version-related variables here (and a few others). `GIT_BRANCH` variable is never used anywhere any more, so it's removed. `BRANCH` was never used anywhere, so it is gone. (It appears to have been added in a25b08c7 but never used). There seemed to be no useful distinction between `DIST` and `BRANCHED`, and both actually seem to be used mainly to specify a release version. The exception is that `BRANCHED` was set to "Modular-Bikeshed" in nightly-modular.sh , but there is no justification for this that I can find, and its only practical use was as the value of the `branch` key in fedmsgs. So far as I can figure out, the original purpose of the `branch` key was for when we sent out `compose.branched.(foo)` fedmsgs - it was e.g. 'f18' when Branched was Fedora 18. As we now don't send out `compose.branched` messages any more, but include the release number in the message topic for Branched messages (e.g. `compose.27`), this purpose no longer applies. So the key just doesn't seem to have any particular use at all any more, and I don't think changing its value will have any real consequences. Thus, `BRANCH`, `BRANCHED` and `DIST` are replaced by `RELEASE` and `RELEASE_TITLE`, which specify the release version. Their values will be identical for numerical release versions, but for Rawhide and Bikeshed we need to know both the lower-case and title-case versions of the name; RELEASE_TITLE is the title-case version. We use `$SHORT-$RELEASE_TITLE` to replace several instances of hardcoding in the scripts (e.g. Fedora-Modular-Bikeshed). The `ATOMIC`, `ATOMICREPO` and `ATOMICDEST` variables that were blindly copied from nightly.sh to nightly-modular.sh, but never actually used in it, are also removed. Signed-off-by: Adam Williamson <awilliam@redhat.com>
2017-12-05 01:24:43 +00:00
send_fedmsg "${fedmsg_json_start}" ${RELEASE} rsync.start
# Sync the content to /pub/fedora
if [ ! -d "$RSYNCTARGET" ]; then
mkdir "$RSYNCTARGET"
fi
$RSYNCPREFIX compose-partial-copy --arch=armhfp --arch=x86_64 --arch src \
"$DESTDIR" "$RSYNCTARGET/" \
--variant Everything --variant AtomicHost --variant Cloud --variant Container \
--variant Server --variant Spins --variant Workstation --variant AtomicWorkstation --variant Modular \
--link-dest="$RSYNCTARGET/Everything" --exclude=repodata
$RSYNCPREFIX compose-partial-copy --arch=armhfp --arch=x86_64 --arch src \
"$DESTDIR" "$RSYNCTARGET/" \
--variant Everything --variant AtomicHost --variant Cloud --variant Container \
--variant Server --variant Spins --variant Workstation --variant AtomicWorkstation --variant Modular \
--link-dest="$RSYNCTARGET/Everything" --delete-after
# aarch64 for Everything Server Cloud Container is primary
$RSYNCPREFIX compose-partial-copy --arch=aarch64 \
"$DESTDIR" "$RSYNCTARGET/" \
--variant Everything --variant Server --variant Cloud --variant Container \
--variant Modular \
--link-dest="$RSYNCTARGET/Everything" --exclude=repodata
$RSYNCPREFIX compose-partial-copy --arch=aarch64 \
"$DESTDIR" "$RSYNCTARGET/" \
--variant Everything --variant Server --variant Cloud --variant Container \
--variant Modular \
--link-dest="$RSYNCTARGET/Everything" --delete-after
$RSYNCPREFIX rm "$RSYNCTARGET/.composeinfo"
$RSYNCPREFIX ./releng/scripts/build_composeinfo "$RSYNCTARGET/" --name "$NEWCOMPOSE_ID"
# Sync the content to /pub/alt
if [ ! -d "$RSYNCALTTARGET" ]; then
mkdir "$RSYNCALTTARGET"
fi
$RSYNCPREFIX compose-partial-copy --arch=armhfp --arch=x86_64 \
"$DESTDIR" "$RSYNCALTTARGET/" \
--variant Labs \
--link-dest="$RSYNCTARGET/Everything/" --exclude=repodata
$RSYNCPREFIX compose-partial-copy --arch=armhfp --arch=x86_64 \
"$DESTDIR" "$RSYNCALTTARGET/" \
--variant Labs \
--link-dest="$RSYNCTARGET/Everything/" --delete-after
$RSYNCPREFIX rm "$RSYNCALTTARGET/.composeinfo"
$RSYNCPREFIX ./releng/scripts/build_composeinfo "$RSYNCALTTARGET/" --name "$NEWCOMPOSE_ID"
# Sync the content to /pub/fedora-secondary
if [ ! -d "$RSYNCSECTARGET" ]; then
mkdir "$RSYNCSECTARGET"
fi
$RSYNCPREFIX compose-partial-copy --arch=i386 --arch=ppc64 --arch=ppc64le --arch=s390x \
"$DESTDIR" "$RSYNCSECTARGET/" \
--variant Everything --variant AtomicHost --variant Cloud --variant Container \
--variant Labs --variant Server --variant Spins --variant Workstation --variant Modular \
--link-dest="$RSYNCTARGET/Everything/" --link-dest="$RSYNCSECTARGET/Everything/" --exclude=repodata
$RSYNCPREFIX compose-partial-copy --arch=i386 --arch=ppc64 --arch=ppc64le --arch=s390x \
"$DESTDIR" "$RSYNCSECTARGET/" \
--variant Everything --variant AtomicHost --variant Cloud --variant Container \
--variant Labs --variant Server --variant Spins --variant Workstation --variant Modular \
--link-dest="$RSYNCTARGET/Everything/" --link-dest="$RSYNCSECTARGET/Everything/" --delete-after
# aarch64 is alternative for AtomicHost Labs Spins Workstation
$RSYNCPREFIX compose-partial-copy --arch=aarch64 \
"$DESTDIR" "$RSYNCSECTARGET/" \
--variant AtomicHost --variant Labs --variant Spins --variant Workstation \
--link-dest="$RSYNCTARGET/Everything/" --exclude=repodata
$RSYNCPREFIX compose-partial-copy --arch=aarch64 \
"$DESTDIR" "$RSYNCSECTARGET/" \
--variant AtomicHost --variant Labs --variant Spins --variant Workstation \
--link-dest="$RSYNCTARGET/Everything/" --delete-after
$RSYNCPREFIX rm "$RSYNCSECTARGET/.composeinfo"
$RSYNCPREFIX ./releng/scripts/build_composeinfo "$RSYNCSECTARGET/" --name "$NEWCOMPOSE_ID"
# sync over atomic host/workstation to the unified ostree repo
for arch in x86_64 aarch64 ppc64le; do
ostree pull-local --repo=$ATOMICDESTREPO $ATOMICSRCREPO --depth=-1 "fedora/rawhide/${arch}/atomic-host"
done
for arch in x86_64; do
ostree pull-local --repo=$ATOMICDESTREPO $ATOMICSRCREPO --depth=-1 "fedora/rawhide/${arch}/workstation"
done
ostree summary -u --repo=$ATOMICDESTREPO # update summary file
# Tell interested persons that the rsync is done.
nightly: include shortname in fedmsgs, clean up version vars The main point here is to include the compose 'shortname' in compose fedmsgs, as #484 does for post-release compose types. While doing this I noticed there's rather a lot of mess and cruft in the various version-related variables here (and a few others). `GIT_BRANCH` variable is never used anywhere any more, so it's removed. `BRANCH` was never used anywhere, so it is gone. (It appears to have been added in a25b08c7 but never used). There seemed to be no useful distinction between `DIST` and `BRANCHED`, and both actually seem to be used mainly to specify a release version. The exception is that `BRANCHED` was set to "Modular-Bikeshed" in nightly-modular.sh , but there is no justification for this that I can find, and its only practical use was as the value of the `branch` key in fedmsgs. So far as I can figure out, the original purpose of the `branch` key was for when we sent out `compose.branched.(foo)` fedmsgs - it was e.g. 'f18' when Branched was Fedora 18. As we now don't send out `compose.branched` messages any more, but include the release number in the message topic for Branched messages (e.g. `compose.27`), this purpose no longer applies. So the key just doesn't seem to have any particular use at all any more, and I don't think changing its value will have any real consequences. Thus, `BRANCH`, `BRANCHED` and `DIST` are replaced by `RELEASE` and `RELEASE_TITLE`, which specify the release version. Their values will be identical for numerical release versions, but for Rawhide and Bikeshed we need to know both the lower-case and title-case versions of the name; RELEASE_TITLE is the title-case version. We use `$SHORT-$RELEASE_TITLE` to replace several instances of hardcoding in the scripts (e.g. Fedora-Modular-Bikeshed). The `ATOMIC`, `ATOMICREPO` and `ATOMICDEST` variables that were blindly copied from nightly.sh to nightly-modular.sh, but never actually used in it, are also removed. Signed-off-by: Adam Williamson <awilliam@redhat.com>
2017-12-05 01:24:43 +00:00
send_fedmsg "${fedmsg_json_done}" ${RELEASE} rsync.complete
# Tell everyone by fedmsg about the compose
nightly: include shortname in fedmsgs, clean up version vars The main point here is to include the compose 'shortname' in compose fedmsgs, as #484 does for post-release compose types. While doing this I noticed there's rather a lot of mess and cruft in the various version-related variables here (and a few others). `GIT_BRANCH` variable is never used anywhere any more, so it's removed. `BRANCH` was never used anywhere, so it is gone. (It appears to have been added in a25b08c7 but never used). There seemed to be no useful distinction between `DIST` and `BRANCHED`, and both actually seem to be used mainly to specify a release version. The exception is that `BRANCHED` was set to "Modular-Bikeshed" in nightly-modular.sh , but there is no justification for this that I can find, and its only practical use was as the value of the `branch` key in fedmsgs. So far as I can figure out, the original purpose of the `branch` key was for when we sent out `compose.branched.(foo)` fedmsgs - it was e.g. 'f18' when Branched was Fedora 18. As we now don't send out `compose.branched` messages any more, but include the release number in the message topic for Branched messages (e.g. `compose.27`), this purpose no longer applies. So the key just doesn't seem to have any particular use at all any more, and I don't think changing its value will have any real consequences. Thus, `BRANCH`, `BRANCHED` and `DIST` are replaced by `RELEASE` and `RELEASE_TITLE`, which specify the release version. Their values will be identical for numerical release versions, but for Rawhide and Bikeshed we need to know both the lower-case and title-case versions of the name; RELEASE_TITLE is the title-case version. We use `$SHORT-$RELEASE_TITLE` to replace several instances of hardcoding in the scripts (e.g. Fedora-Modular-Bikeshed). The `ATOMIC`, `ATOMICREPO` and `ATOMICDEST` variables that were blindly copied from nightly.sh to nightly-modular.sh, but never actually used in it, are also removed. Signed-off-by: Adam Williamson <awilliam@redhat.com>
2017-12-05 01:24:43 +00:00
send_fedmsg "${fedmsg_json_done}" ${RELEASE} complete
# Tell everyone by email about the compose
# "$DESTDIR/logs/depcheck" lets not cat out depcheck for now as it does
# not understand rich dependencies
nightly: include shortname in fedmsgs, clean up version vars The main point here is to include the compose 'shortname' in compose fedmsgs, as #484 does for post-release compose types. While doing this I noticed there's rather a lot of mess and cruft in the various version-related variables here (and a few others). `GIT_BRANCH` variable is never used anywhere any more, so it's removed. `BRANCH` was never used anywhere, so it is gone. (It appears to have been added in a25b08c7 but never used). There seemed to be no useful distinction between `DIST` and `BRANCHED`, and both actually seem to be used mainly to specify a release version. The exception is that `BRANCHED` was set to "Modular-Bikeshed" in nightly-modular.sh , but there is no justification for this that I can find, and its only practical use was as the value of the `branch` key in fedmsgs. So far as I can figure out, the original purpose of the `branch` key was for when we sent out `compose.branched.(foo)` fedmsgs - it was e.g. 'f18' when Branched was Fedora 18. As we now don't send out `compose.branched` messages any more, but include the release number in the message topic for Branched messages (e.g. `compose.27`), this purpose no longer applies. So the key just doesn't seem to have any particular use at all any more, and I don't think changing its value will have any real consequences. Thus, `BRANCH`, `BRANCHED` and `DIST` are replaced by `RELEASE` and `RELEASE_TITLE`, which specify the release version. Their values will be identical for numerical release versions, but for Rawhide and Bikeshed we need to know both the lower-case and title-case versions of the name; RELEASE_TITLE is the title-case version. We use `$SHORT-$RELEASE_TITLE` to replace several instances of hardcoding in the scripts (e.g. Fedora-Modular-Bikeshed). The `ATOMIC`, `ATOMICREPO` and `ATOMICDEST` variables that were blindly copied from nightly.sh to nightly-modular.sh, but never actually used in it, are also removed. Signed-off-by: Adam Williamson <awilliam@redhat.com>
2017-12-05 01:24:43 +00:00
SUBJECT='Fedora '$RELEASE' compose report: '$SHORTCOMPOSE_ID' changes'
for tomail in $TOMAIL ; do
cat $DESTDIR/logs/*verbose | \
mutt -e "set from=\"$FROM\"" -e 'set envelope_from=yes' -s "$SUBJECT" $tomail
done
find $TARGET_DIR -xdev -depth -maxdepth 2 -mtime +14 -exec rm -rf {} \;