Merge pull request #90 from gurnec/grub-pc
prevent upgrade of grub-pc which can fail in lxc
This commit is contained in:
commit
df8381baff
@ -7,6 +7,7 @@ set -e
|
|||||||
cd /var/cache/apt/archives
|
cd /var/cache/apt/archives
|
||||||
|
|
||||||
# make sure all packages with installed versions are downloaded
|
# make sure all packages with installed versions are downloaded
|
||||||
dpkg-query -W -f '${Package}=${Version}\n' | xargs -n 50 apt-get install -q --reinstall -y -d > /tmp/download.log
|
# (except for held packages, which may not be available for download)
|
||||||
|
dpkg-query -W -f '${Status}\t${Package}=${Version}\n' | grep -v ^hold | cut -f2- | xargs -n 50 apt-get install -q --reinstall -y -d > /tmp/download.log
|
||||||
grep "cannot be downloaded" /tmp/download.log && { echo Could not download some packages, please run gbuild --upgrade 1>&2 ; exit 1 ; }
|
grep "cannot be downloaded" /tmp/download.log && { echo Could not download some packages, please run gbuild --upgrade 1>&2 ; exit 1 ; }
|
||||||
sha256sum *.deb | sort --key 2
|
sha256sum *.deb | sort --key 2
|
||||||
|
@ -9,6 +9,9 @@ mkdir -p /var/cache/gitian
|
|||||||
# remove obsolete grub, it causes package dependency issues
|
# remove obsolete grub, it causes package dependency issues
|
||||||
apt-get -q -y purge grub > /dev/null 2>&1 || true
|
apt-get -q -y purge grub > /dev/null 2>&1 || true
|
||||||
|
|
||||||
|
# prevent upgrade of grub-pc, it fails to find a boot drive in lxc containers
|
||||||
|
echo grub-pc hold | dpkg --set-selections || true
|
||||||
|
|
||||||
# upgrade packages
|
# upgrade packages
|
||||||
DEBIAN_FRONTEND=noninteractive apt-get -y dist-upgrade > /dev/null > /var/cache/gitian/upgrade.log 2>&1
|
DEBIAN_FRONTEND=noninteractive apt-get -y dist-upgrade > /dev/null > /var/cache/gitian/upgrade.log 2>&1
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user