diskimage-builder/elements/debian-upstart/root.d/20-debian-fix-upstart-jobs
Clint Byrum 611a8b701a Add debian-upstart for experimenting with upstart
Upstart support in Debian is somewhat experimental, but having it would
be especially useful for TripleO which already generates upstart scripts
which will work fairly well on Debian based systems.

Change-Id: I267da5ae7bc4a484fac152a14963d96ca2ad2693
2014-01-14 22:41:25 -08:00

12 lines
640 B
Bash
Executable File

#!/bin/bash
set -eux
# Working around bug in Debian cloud-init packages with upstart
# where startpar will wait forever for these because they are tasks
# http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=735204
for sysv_script in cloud-init cloud-init-local cloud-config cloud-final ; do
sudo rm -f ${TARGET_ROOT}/etc/rc2.d/??${sysv_script} ${TARGET_ROOT}/etc/init.d/${sysv_script}
done
# And working around upstart job bug in Debian where cloud-config will never run
# http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=735207
sudo sed -i -e 's/start on .*/start on started rc RUNLEVEL=[2345]/' ${TARGET_ROOT}/etc/init/cloud-config.conf