aboutsummaryrefslogtreecommitdiff
path: root/init.d
diff options
context:
space:
mode:
authorMike Gilbert <floppym@gentoo.org>2015-05-28 00:01:43 -0400
committerWilliam Hubbs <w.d.hubbs@gmail.com>2015-06-02 13:11:04 -0500
commitb209fe3859c05c286037843bb34058f849c54b15 (patch)
treed9cc74dcf12041ca23856c4b2f5a9be424f91930 /init.d
parentc94c8288cd5217b01c24d6f048c64ebbc30bee02 (diff)
bootmisc: Don't call dmesg in systemd-nspawn containers
This fixes #57.
Diffstat (limited to 'init.d')
-rw-r--r--init.d/bootmisc.in11
1 files changed, 7 insertions, 4 deletions
diff --git a/init.d/bootmisc.in b/init.d/bootmisc.in
index dbd258e8..13f23891 100644
--- a/init.d/bootmisc.in
+++ b/init.d/bootmisc.in
@@ -214,10 +214,13 @@ start()
if yesno $log_dmesg; then
if $logw || checkpath -W /var/log; then
# Create an 'after-boot' dmesg log
- if [ "$RC_SYS" != VSERVER -a "$RC_SYS" != OPENVZ -a "$RC_SYS" != LXC ]; then
- dmesg > /var/log/dmesg
- chmod 640 /var/log/dmesg
- fi
+ case "$RC_SYS" in
+ VSERVER|OPENVZ|LXC|SYSTEMD-NSPAWN) ;;
+ *)
+ dmesg > /var/log/dmesg
+ chmod 640 /var/log/dmesg
+ ;;
+ esac
fi
fi