From 675e4924562609fb183f9192cff4bb05567712e6 Mon Sep 17 00:00:00 2001 From: Martin Pitt Date: Tue, 11 Apr 2023 05:47:43 +0200 Subject: [PATCH] build-debian-toolbox: forward podman/toolbox commands to host --- build-debian-toolbox | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/build-debian-toolbox b/build-debian-toolbox index 8286876..734f42f 100755 --- a/build-debian-toolbox +++ b/build-debian-toolbox @@ -41,10 +41,16 @@ sudo hostname -F /etc/hostname sudo eatmydata apt-get -y dist-upgrade # development tools -sudo eatmydata apt-get install -y --no-install-recommends build-essential git-buildpackage libwww-perl less vim lintian debhelper manpages-dev git dput pristine-tar bash-completion wget gnupg ubuntu-dev-tools python3-debian fakeroot libdistro-info-perl openssh-client +sudo eatmydata apt-get install -y --no-install-recommends build-essential git-buildpackage libwww-perl less vim lintian debhelper manpages-dev git dput pristine-tar bash-completion wget gnupg ubuntu-dev-tools python3-debian fakeroot libdistro-info-perl openssh-client flatpak-xdg-utils # autopkgtest sudo eatmydata apt-get install -y --no-install-recommends autopkgtest qemu-system-x86 qemu-utils genisoimage + +# commands to forward to the host +for cmd in podman toolbox; do + printf "#!/bin/sh\n/usr/libexec/flatpak-xdg-utils/flatpak-spawn --host $cmd \42\$@\42\n" | sudo tee /usr/local/bin/$cmd >/dev/null + sudo chmod a+x /usr/local/bin/$cmd +done ' toolbox enter --container $RELEASE -- 2.39.5