Merge lp:~ondrak/lxc-android-config/fix_1551150 into lp:lxc-android-config

Proposed by Ondrej Kubik
Status: Merged
Approved by: Łukasz Zemczak
Approved revision: 21
Merged at revision: 21
Proposed branch: lp:~ondrak/lxc-android-config/fix_1551150
Merge into: lp:lxc-android-config
Diff against target: 50 lines (+18/-9)
1 file modified
debian/lxc-android-config.upstart (+18/-9)
To merge this branch: bzr merge lp:~ondrak/lxc-android-config/fix_1551150
Reviewer Review Type Date Requested Status
Łukasz Zemczak Approve
Review via email: mp+297622@code.launchpad.net

Commit message

Updating lxc-android-config to work with new lxc v2.0. This fixes boot of devel-proposed (Xenial) channel (LP: #1551150)

Description of the change

Updating lxc-android-config to work with new lxc v2.0

This fixes boot of devel-proposed (Xenial) channel

bug: https://bugs.launchpad.net/bugs/1551150

To post a comment you must log in.
Revision history for this message
Łukasz Zemczak (sil2100) wrote :

+1

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'debian/lxc-android-config.upstart'
--- debian/lxc-android-config.upstart 2015-09-02 07:50:44 +0000
+++ debian/lxc-android-config.upstart 2016-06-16 12:56:07 +0000
@@ -2,21 +2,23 @@
2#2#
3# Configure and initialize the Android container for Ubuntu Touch3# Configure and initialize the Android container for Ubuntu Touch
44
5description "lxc android config and container initialization"5description "lxc android config and container initialization"
66
7start on cgmanager-ready7start on cgmanager-ready and started cgroup-lite
8stop on runlevel [06]8stop on runlevel [06]
99
10emits android10pre-start script
1111 if [ ! -d /sys/fs/cgroup/systemd ]; then
12console none12 mkdir -p /sys/fs/cgroup/systemd
1313 mount -t cgroup cgroup /sys/fs/cgroup/systemd -o name=systemd
14exec lxc-start -n android -F -- /init14 fi
15end script
16
17exec lxc-start -n android -d -- /init
1518
16post-start script19post-start script
17 if [ ! -d /dev/cpuctl ] && [ -d /sys/fs/cgroup/cpu ]; then20 if [ ! -d /dev/cpuctl ] && [ -d /sys/fs/cgroup/cpu ]; then
18 mkdir /dev/cpuctl21 ln -s /sys/fs/cgroup/cpu /dev/cpuctl
19 mount -t cgroup -o cpu none /sys/fs/cgroup/cpu
20 fi22 fi
2123
22 lxc-wait -n android -s RUNNING -t 3024 lxc-wait -n android -s RUNNING -t 30
@@ -35,6 +37,13 @@
35 done37 done
36 fi38 fi
3739
40 # Hide all the cgroups again
41 stop cgroup-lite
42 if [ -d /sys/fs/cgroup/systemd ]; then
43 umount /sys/fs/cgroup/systemd
44 rmdir /sys/fs/cgroup/systemd
45 fi
46
38 initctl emit android47 initctl emit android
39 else48 else
40 stop; exit 149 stop; exit 1

Subscribers

People subscribed via source and target branches