Package: anbox
Version: 0.0~git20190124-1
Severity: important

When starting anbox-container-manager.service it fail with "Condition check 
resulted in Anbox Container Manager being skipped" and anbox session-manager 
failing to start.

This bug prevent starting anbox.

transcript:
$ sudo modprobe ashmem_linux
$ sudo modprobe binder_linux       
$ sudo systemctl start anbox-container-manager.service 
$ sudo tail -f /var/log/syslog
Jul 30 04:19:58 buster systemd[1]: Condition check resulted in Anbox Container 
Manager being skipped.

$env ANBOX_LOG_LEVEL=debug  anbox session-manager
[ 2019-07-30 04:20:36] [daemon.cpp:61@Run] Failed to connect to socket /run/
anbox-container.socket: No such file or directory

This quilt patch fixes that issue.

-- Boris Shtrasman
>From bbfcc2e35bbd52671fc55e47036ff1308af63767 Mon Sep 17 00:00:00 2001
From: Boris Shtrasman <bo...@example.com>
Date: Tue, 30 Jul 2019 05:17:13 +0300
Subject: [PATCH] BUGFIX: systemd exec should be using an executable

Exec= should be followd by an executable (or an interpriatator in case
of shell scripts) to be called.

this bugfix fixes "Condition check resulted in Anbox Container Manager
being skipped" error when starting anbox-container-manager.service
---
 debian/patches/0007-serviceshouldcallbash.patch | 15 +++++++++++++++
 debian/patches/series                           |  1 +
 2 files changed, 16 insertions(+)
 create mode 100644 debian/patches/0007-serviceshouldcallbash.patch

diff --git a/debian/patches/0007-serviceshouldcallbash.patch b/debian/patches/0007-serviceshouldcallbash.patch
new file mode 100644
index 0000000..389f7ea
--- /dev/null
+++ b/debian/patches/0007-serviceshouldcallbash.patch
@@ -0,0 +1,15 @@
+Shell scripts should be passed to an interpretator  to be used when using exec
+--- a/debian/anbox-container-manager.service
++++ b/debian/anbox-container-manager.service
+@@ -8,9 +8,9 @@ ConditionPathExists=/var/lib/anbox/andro
+ [Service]
+ ExecStartPre=/sbin/modprobe ashmem_linux
+ ExecStartPre=/sbin/modprobe binder_linux
+-ExecStartPre=/usr/share/anbox/anbox-bridge.sh start
++ExecStartPre=/bin/sh /usr/share/anbox/anbox-bridge.sh start
+ ExecStart=/usr/bin/anbox container-manager --daemon --privileged --data-path=/var/lib/anbox
+-ExecStopPost=/usr/share/anbox/anbox-bridge.sh stop
++ExecStopPost=/bin/sh /usr/share/anbox/anbox-bridge.sh stop
+ 
+ [Install]
+ WantedBy=multi-user.target
diff --git a/debian/patches/series b/debian/patches/series
index 710ad29..0f8fb1e 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -3,3 +3,4 @@
 0004-exclude-external-from-all-target.patch
 0005-pass-dpkg-buildflags-to-external-android-emugl.patch
 0006-unsafe-workaround-for-issue-1057.patch
+0007-serviceshouldcallbash.patch
-- 
2.20.1

Reply via email to