]> git.ipfire.org Git - ipfire-3.x.git/commitdiff
upstart: Make shutdown/reboot comfortable.
authorMichael Tremer <michael.tremer@ipfire.org>
Sat, 22 Aug 2009 12:38:50 +0000 (14:38 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Sat, 22 Aug 2009 12:38:50 +0000 (14:38 +0200)
lfs/upstart
src/profile.d/upstart.sh [new file with mode: 0644]

index 6f2392ed05fdc0849b37dbc6193cf859e6720fd6..2219a0cc7ff0490e3d105f836e919db88ea40df9 100644 (file)
@@ -105,5 +105,9 @@ $(OBJECT): $(objects)
        rm -vf /etc/init/rc.conf
        rm -vf /etc/init/rcS.conf
 
+       # Make shutdown/reboot comfortable.
+       -mkdir -pv /etc/profile.d
+       cp -vf $(DIR_SOURCE)/profile.d/upstart.conf /etc/profile.d
+
        @rm -rf $(DIR_APP)
        @$(POSTBUILD)
diff --git a/src/profile.d/upstart.sh b/src/profile.d/upstart.sh
new file mode 100644 (file)
index 0000000..73c71a0
--- /dev/null
@@ -0,0 +1,6 @@
+# Some nice upstart hooks
+
+alias halt="initctl emit --no-wait shutdown"
+alias poweroff="initctl emit --no-wait shutdown"
+alias reboot="initctl emit --no-wait reboot"
+alias shutdown="initctl emit --no-wait shutdown"