From 2d34cbcfb92df4f9bf223fec5a707748a2278df0 Mon Sep 17 00:00:00 2001 From: Alexander Mikhalitsyn Date: Wed, 9 Oct 2024 12:06:26 +0200 Subject: [PATCH 1/2] snapcraft: apply temporary workaround for core24 to fix snap reload This reverts commit 005d24917d421fa3f96e58f1382f27cac73b080e. Signed-off-by: Alexander Mikhalitsyn --- snapcraft/commands/daemon.start | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/snapcraft/commands/daemon.start b/snapcraft/commands/daemon.start index 19d375b5..1080e126 100755 --- a/snapcraft/commands/daemon.start +++ b/snapcraft/commands/daemon.start @@ -39,6 +39,13 @@ fi # Detect base name SNAP_BASE="$(sed -n '/^name:/ s/^name:\s*\(core[0-9]\{2\}\)/\1/p' /meta/snap.yaml)" +# Temporary hack to workaround systemctl reload snap.lxd.daemon +# problem with core24-based LXD snap +if [ "${SNAP_BASE}" = "core24" ]; then + _LXD_SNAP_DEVCGROUP_CONFIG="/var/lib/snapd/hostfs/var/lib/snapd/cgroup/snap.lxd.device" + grep -qxF 'self-managed=true' "${_LXD_SNAP_DEVCGROUP_CONFIG}" || echo 'self-managed=true' >> "${_LXD_SNAP_DEVCGROUP_CONFIG}" +fi + # Wait for appliance configuration if [ "${LXD_APPLIANCE}" = "true" ]; then while :; do From df71027c2ae18380e8f7a0db76da26aaf4dda09a Mon Sep 17 00:00:00 2001 From: Alexander Mikhalitsyn Date: Wed, 9 Oct 2024 12:07:07 +0200 Subject: [PATCH 2/2] Revert "snapcraft: bump snapd version requirement to 2.65" This reverts commit ff8df89229a6ded76151dbe5045e7263e97a4116. Signed-off-by: Alexander Mikhalitsyn --- snapcraft.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/snapcraft.yaml b/snapcraft.yaml index eaf42d43..285f66d8 100644 --- a/snapcraft.yaml +++ b/snapcraft.yaml @@ -1,7 +1,7 @@ name: lxd base: core24 assumes: - - snapd2.65 + - snapd2.39 version: git grade: devel summary: LXD - container and VM manager