From e68fc821cf02dd53cd18e608696f907f2d59272f Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Sun, 14 Aug 2022 18:07:04 +0200 Subject: [PATCH 1/4] bullseye migration: trash pip freeze stderr because it's confusing users ... --- src/yunohost/data_migrations/0021_migrate_to_bullseye.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/yunohost/data_migrations/0021_migrate_to_bullseye.py b/src/yunohost/data_migrations/0021_migrate_to_bullseye.py index ce7d25262..e8f664675 100644 --- a/src/yunohost/data_migrations/0021_migrate_to_bullseye.py +++ b/src/yunohost/data_migrations/0021_migrate_to_bullseye.py @@ -66,7 +66,7 @@ def _backup_pip_freeze_for_python_app_venvs(): venvs = _get_all_venvs("/opt/") + _get_all_venvs("/var/www/") for venv in venvs: # Generate a requirements file from venv - os.system(f"{venv}/bin/pip freeze > {venv}{VENV_REQUIREMENTS_SUFFIX}") + os.system(f"{venv}/bin/pip freeze > {venv}{VENV_REQUIREMENTS_SUFFIX} 2>/dev/null") class MyMigration(Migration): From 02fcbd9792f35b9edf9aa635779ae79fa6cc9345 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Sun, 14 Aug 2022 18:10:10 +0200 Subject: [PATCH 2/4] bullseye migration: add a check that there's at least 70MB available in /boot ... --- src/yunohost/data_migrations/0021_migrate_to_bullseye.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/yunohost/data_migrations/0021_migrate_to_bullseye.py b/src/yunohost/data_migrations/0021_migrate_to_bullseye.py index e8f664675..9b11f8084 100644 --- a/src/yunohost/data_migrations/0021_migrate_to_bullseye.py +++ b/src/yunohost/data_migrations/0021_migrate_to_bullseye.py @@ -373,6 +373,9 @@ class MyMigration(Migration): if free_space_in_directory("/var/") / (1024**3) < 1.0: raise YunohostError("migration_0021_not_enough_free_space") + if free_space_in_directory("/boot/") / (70**3) < 1.0: + raise YunohostError("/boot/ has less than 70MB available. This will probably trigger a crash during the upgrade because a new kernel needs to be installed. Please look for advice on the forum on how to remove old unused kernels to free some space in /boot/.", raw_msg=True) + # Check system is up to date # (but we don't if 'bullseye' is already in the sources.list ... # which means maybe a previous upgrade crashed and we're re-running it) From 633a1fbffe5b374c30814f9152ed0f5883513804 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Sun, 14 Aug 2022 18:17:24 +0200 Subject: [PATCH 3/4] bullseye migration: better detection mechanism for the libc6 / libgcc hell issue --- src/yunohost/data_migrations/0021_migrate_to_bullseye.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/yunohost/data_migrations/0021_migrate_to_bullseye.py b/src/yunohost/data_migrations/0021_migrate_to_bullseye.py index 9b11f8084..7a47941a1 100644 --- a/src/yunohost/data_migrations/0021_migrate_to_bullseye.py +++ b/src/yunohost/data_migrations/0021_migrate_to_bullseye.py @@ -201,7 +201,7 @@ class MyMigration(Migration): # Another boring fix for the super annoying libc6-dev: Breaks libgcc-8-dev # https://forum.yunohost.org/t/20617 # - if os.system("grep -A10 'ynh-deps' /var/lib/dpkg/status | grep -q 'Depends:.*build-essential'") == 0: + if os.sytem("dpkg --list | grep '^ii' | grep -q ' libgcc-8-dev '") == 0 and os.system("LC_ALL=C apt policy libgcc-8-dev | grep Candidate | grep -q rpi"): logger.info("Attempting to fix the build-essential / libc6-dev / libgcc-8-dev hell ...") os.system("cp /var/lib/dpkg/status /root/dpkg_status.bkp") # This removes the dependency to build-essential from $app-ynh-deps From 0a66d039c2b583d416f52e8230009491314a2933 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Sun, 14 Aug 2022 18:18:55 +0200 Subject: [PATCH 4/4] Update changelog for 4.4.2.4 --- debian/changelog | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/debian/changelog b/debian/changelog index be9c07de5..3ad7323d1 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +yunohost (4.4.2.4) stable; urgency=low + + - [fix] bullseye migration: trash pip freeze stderr because it's confusing users ... (e68fc821) + - [fix] bullseye migration: add a check that there's at least 70MB available in /boot ... (02fcbd97) + - [fix] bullseye migration: better detection mechanism for the libc6 / libgcc hell issue (633a1fbf) + + -- Alexandre Aubin Sun, 14 Aug 2022 18:18:13 +0200 + yunohost (4.4.2.3) stable; urgency=low - [fix] bullseye migration: add fix for stupid dnsmasq not picking new init script (origin/dev, origin/HEAD, dev)