Merge lp:~jibel/ubuntu/raring/flash-kernel/skip_inside_lxc_container into lp:ubuntu/raring/flash-kernel

Proposed by Jean-Baptiste Lallement
Status: Merged
Merge reported by: Loïc Minier
Merged at revision: not available
Proposed branch: lp:~jibel/ubuntu/raring/flash-kernel/skip_inside_lxc_container
Merge into: lp:ubuntu/raring/flash-kernel
Diff against target: 63 lines (+23/-0)
4 files modified
debian/changelog (+6/-0)
initramfs-hook/flash-kernel (+6/-0)
initramfs-tools/hooks/flash_kernel_set_root (+6/-0)
kernel-hook/zz-flash-kernel (+5/-0)
To merge this branch: bzr merge lp:~jibel/ubuntu/raring/flash-kernel/skip_inside_lxc_container
Reviewer Review Type Date Requested Status
Loïc Minier Approve
Ubuntu branches Pending
Review via email: mp+155772@code.launchpad.net

Description of the change

This patch skips flash-kernel when run inside an LXC container by checking the result of 'running-in-container'

To post a comment you must log in.
Revision history for this message
Loïc Minier (lool) wrote :

LGTM

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'debian/changelog'
--- debian/changelog 2012-12-04 17:24:49 +0000
+++ debian/changelog 2013-03-27 15:48:25 +0000
@@ -1,3 +1,9 @@
1flash-kernel (3.0~rc.4ubuntu30) raring; urgency=low
2
3 * Do not run flash-kernel inside an LXC container (LP: #1160360)
4
5 -- Jean-Baptiste Lallement <jean-baptiste.lallement@canonical.com> Wed, 27 Mar 2013 16:29:20 +0100
6
1flash-kernel (3.0~rc.4ubuntu29) raring; urgency=low7flash-kernel (3.0~rc.4ubuntu29) raring; urgency=low
28
3 * determine the latest installer kernel version in the target rootfs instead9 * determine the latest installer kernel version in the target rootfs instead
410
=== modified file 'initramfs-hook/flash-kernel'
--- initramfs-hook/flash-kernel 2012-06-22 11:20:39 +0000
+++ initramfs-hook/flash-kernel 2013-03-27 15:48:25 +0000
@@ -13,6 +13,12 @@
13 exit 013 exit 0
14fi14fi
1515
16# Do not run inside an LXC container
17if type running-in-container >/dev/null 2>&1 && \
18 running-in-container >/dev/null; then
19 exit 0
20fi
21
16abi="$1"22abi="$1"
17# ignored23# ignored
18_initrd="$2"24_initrd="$2"
1925
=== modified file 'initramfs-tools/hooks/flash_kernel_set_root'
--- initramfs-tools/hooks/flash_kernel_set_root 2012-09-13 14:02:48 +0000
+++ initramfs-tools/hooks/flash_kernel_set_root 2013-03-27 15:48:25 +0000
@@ -57,6 +57,12 @@
57 exit 057 exit 0
58fi58fi
5959
60# Do not run inside an LXC container
61if type running-in-container >/dev/null 2>&1 && \
62 running-in-container >/dev/null; then
63 exit 0
64fi
65
60# Record the root filesystem device for use during boot66# Record the root filesystem device for use during boot
61rootdev=$(egrep '^[^# ]+[ ]+/[ ]' /etc/fstab | awk '{print $1}') || true67rootdev=$(egrep '^[^# ]+[ ]+/[ ]' /etc/fstab | awk '{print $1}') || true
6268
6369
=== modified file 'kernel-hook/zz-flash-kernel'
--- kernel-hook/zz-flash-kernel 2012-06-20 16:41:28 +0000
+++ kernel-hook/zz-flash-kernel 2013-03-27 15:48:25 +0000
@@ -15,6 +15,11 @@
15 exit 015 exit 0
16fi16fi
1717
18# Do not run inside an LXC container
19if type running-in-container >/dev/null 2>&1 && \
20 running-in-container >/dev/null; then
21 exit 0
22fi
1823
19# this script is used as postinst.d and postrm.d script; this is used to24# this script is used as postinst.d and postrm.d script; this is used to
20# differentiate between the two25# differentiate between the two

Subscribers

People subscribed via source and target branches