[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[Rdo-list] [PATCH] openstack-nova juno el6



Hi All,

I finally had time to publish my changes.

Please review.

Thanks to number80 for the helping with dependencies rebuilding (oslo* , epel, etc...)

--
Thomas.
>From fc3a5129f24ef0f5899737375470a9769c0c08b7 Mon Sep 17 00:00:00 2001
From: Thomas Oulevey <thomas oulevey cern ch>
Date: Mon, 9 Mar 2015 17:45:41 +0100
Subject: [PATCH] juno spec for el6

---
 openstack-nova-api.init                |  110 ++++++++
 openstack-nova-api.upstart             |    8 +
 openstack-nova-cells.init              |  102 +++++++
 openstack-nova-cells.upstart           |    8 +
 openstack-nova-cert.init               |  102 +++++++
 openstack-nova-cert.upstart            |    8 +
 openstack-nova-compute.init            |  118 ++++++++
 openstack-nova-compute.upstart         |    8 +
 openstack-nova-conductor.init          |  102 +++++++
 openstack-nova-conductor.upstart       |    8 +
 openstack-nova-console.init            |  102 +++++++
 openstack-nova-console.upstart         |    8 +
 openstack-nova-consoleauth.init        |  102 +++++++
 openstack-nova-consoleauth.upstart     |    8 +
 openstack-nova-metadata-api.init       |  102 +++++++
 openstack-nova-metadata-api.upstart    |    8 +
 openstack-nova-network.init            |  116 ++++++++
 openstack-nova-network.upstart         |    8 +
 openstack-nova-novncproxy.init         |  102 +++++++
 openstack-nova-novncproxy.upstart      |    8 +
 openstack-nova-objectstore.init        |  102 +++++++
 openstack-nova-objectstore.upstart     |    8 +
 openstack-nova-scheduler.init          |  102 +++++++
 openstack-nova-scheduler.upstart       |    8 +
 openstack-nova-serialproxy.init        |  102 +++++++
 openstack-nova-serialproxy.upstart     |    8 +
 openstack-nova-spicehtml5proxy.init    |  102 +++++++
 openstack-nova-spicehtml5proxy.upstart |    8 +
 openstack-nova-xvpvncproxy.init        |  102 +++++++
 openstack-nova-xvpvncproxy.upstart     |    8 +
 openstack-nova.spec                    |  458 +++++++++++++++++++++++++++++++-
 31 files changed, 2143 insertions(+), 3 deletions(-)
 create mode 100644 openstack-nova-api.init
 create mode 100644 openstack-nova-api.upstart
 create mode 100644 openstack-nova-cells.init
 create mode 100644 openstack-nova-cells.upstart
 create mode 100644 openstack-nova-cert.init
 create mode 100644 openstack-nova-cert.upstart
 create mode 100644 openstack-nova-compute.init
 create mode 100644 openstack-nova-compute.upstart
 create mode 100644 openstack-nova-conductor.init
 create mode 100644 openstack-nova-conductor.upstart
 create mode 100644 openstack-nova-console.init
 create mode 100644 openstack-nova-console.upstart
 create mode 100644 openstack-nova-consoleauth.init
 create mode 100644 openstack-nova-consoleauth.upstart
 create mode 100644 openstack-nova-metadata-api.init
 create mode 100644 openstack-nova-metadata-api.upstart
 create mode 100644 openstack-nova-network.init
 create mode 100644 openstack-nova-network.upstart
 create mode 100644 openstack-nova-novncproxy.init
 create mode 100644 openstack-nova-novncproxy.upstart
 create mode 100644 openstack-nova-objectstore.init
 create mode 100644 openstack-nova-objectstore.upstart
 create mode 100644 openstack-nova-scheduler.init
 create mode 100644 openstack-nova-scheduler.upstart
 create mode 100644 openstack-nova-serialproxy.init
 create mode 100644 openstack-nova-serialproxy.upstart
 create mode 100644 openstack-nova-spicehtml5proxy.init
 create mode 100644 openstack-nova-spicehtml5proxy.upstart
 create mode 100644 openstack-nova-xvpvncproxy.init
 create mode 100644 openstack-nova-xvpvncproxy.upstart

diff --git a/openstack-nova-api.init b/openstack-nova-api.init
new file mode 100644
index 0000000..ff6f525
--- /dev/null
+++ b/openstack-nova-api.init
@@ -0,0 +1,110 @@
+#!/bin/sh
+#
+# openstack-nova-api  OpenStack Nova API Server
+#
+# chkconfig:   - 98 02
+# description: At the heart of the cloud framework is an API Server. \
+#              This API Server makes command and control of the      \
+#              hypervisor, storage, and networking programmatically  \
+#              available to users in realization of the definition   \
+#              of cloud computing.
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova API Server
+# Description: At the heart of the cloud framework is an API Server.
+#              This API Server makes command and control of the
+#              hypervisor, storage, and networking programmatically
+#              available to users in realization of the definition
+#              of cloud computing.
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=api
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-$suffix"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --logfile $logfile &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-api.upstart b/openstack-nova-api.upstart
new file mode 100644
index 0000000..24274e0
--- /dev/null
+++ b/openstack-nova-api.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova API Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-api --logfile /var/log/nova/api.log" nova
diff --git a/openstack-nova-cells.init b/openstack-nova-cells.init
new file mode 100644
index 0000000..83baf10
--- /dev/null
+++ b/openstack-nova-cells.init
@@ -0,0 +1,102 @@
+#!/bin/sh
+#
+# openstack-nova-cells  OpenStack Nova Compute Cells service
+#
+# chkconfig:   - 98 02
+# description: Implementation of an S3-like storage server based on local files.
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova Compute DB Access service
+# Description: Service to handle database access for compute nodes
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=cells
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-$suffix"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --logfile $logfile &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-cells.upstart b/openstack-nova-cells.upstart
new file mode 100644
index 0000000..bb0bbdd
--- /dev/null
+++ b/openstack-nova-cells.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova Cells Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-cells --logfile /var/log/nova/cells.log" nova
diff --git a/openstack-nova-cert.init b/openstack-nova-cert.init
new file mode 100644
index 0000000..1ce65a8
--- /dev/null
+++ b/openstack-nova-cert.init
@@ -0,0 +1,102 @@
+#!/bin/sh
+#
+# openstack-nova-cert  OpenStack Nova cert Worker
+#
+# chkconfig:   - 98 02
+# description: cert manages auth cert access and creation
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova Cert Manager
+# Description: cert manages auth cert access and creation
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=cert
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-$suffix"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --logfile $logfile &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-cert.upstart b/openstack-nova-cert.upstart
new file mode 100644
index 0000000..6480c76
--- /dev/null
+++ b/openstack-nova-cert.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova Cert Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-cert --logfile /var/log/nova/cert.log" nova
diff --git a/openstack-nova-compute.init b/openstack-nova-compute.init
new file mode 100644
index 0000000..0e6adc7
--- /dev/null
+++ b/openstack-nova-compute.init
@@ -0,0 +1,118 @@
+#!/bin/sh
+#
+# openstack-nova-compute  OpenStack Nova Compute Worker
+#
+# chkconfig:   - 98 02
+# description: Compute workers manage computing instances on host  \
+#               machines. Through the API, commands are dispatched \
+#               to compute workers to:                             \
+#               * Run instances                                    \
+#               * Terminate instances                              \
+#               * Reboot instances                                 \
+#               * Attach volumes                                   \
+#               * Detach volumes                                   \
+#               * Get console output
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova Compute Worker
+# Description: Compute workers manage computing instances on host
+#               machines. Through the API, commands are dispatched
+#               to compute workers to:
+#               * Run instances
+#               * Terminate instances
+#               * Reboot instances
+#               * Attach volumes
+#               * Detach volumes
+#               * Get console output
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=compute
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-$suffix"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --logfile $logfile &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-compute.upstart b/openstack-nova-compute.upstart
new file mode 100644
index 0000000..5ff3f06
--- /dev/null
+++ b/openstack-nova-compute.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova Compute Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-compute --logfile /var/log/nova/compute.log" nova
diff --git a/openstack-nova-conductor.init b/openstack-nova-conductor.init
new file mode 100644
index 0000000..34548e4
--- /dev/null
+++ b/openstack-nova-conductor.init
@@ -0,0 +1,102 @@
+#!/bin/sh
+#
+# openstack-nova-conductor  OpenStack Nova Compute DB Access service
+#
+# chkconfig:   - 98 02
+# description: Implementation of an S3-like storage server based on local files.
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova Compute DB Access service
+# Description: Service to handle database access for compute nodes
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=conductor
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-$suffix"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --logfile $logfile &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-conductor.upstart b/openstack-nova-conductor.upstart
new file mode 100644
index 0000000..bd2abb7
--- /dev/null
+++ b/openstack-nova-conductor.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova Conductor Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-conductor --logfile /var/log/nova/conductor.log" nova
diff --git a/openstack-nova-console.init b/openstack-nova-console.init
new file mode 100644
index 0000000..b21ae59
--- /dev/null
+++ b/openstack-nova-console.init
@@ -0,0 +1,102 @@
+#!/bin/sh
+#
+# openstack-nova-console  OpenStack Nova Console Proxy
+#
+# chkconfig:   - 98 02
+# description: OpenStack Nova Console Proxy Server
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova Console Proxy
+# Description: OpenStack Nova Console Proxy Server
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=console
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-$suffix"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --logfile $logfile &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-console.upstart b/openstack-nova-console.upstart
new file mode 100644
index 0000000..ebbc2b2
--- /dev/null
+++ b/openstack-nova-console.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova Console Proxy Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-console --logfile /var/log/nova/console.log" nova
diff --git a/openstack-nova-consoleauth.init b/openstack-nova-consoleauth.init
new file mode 100644
index 0000000..a904a27
--- /dev/null
+++ b/openstack-nova-consoleauth.init
@@ -0,0 +1,102 @@
+#!/bin/sh
+#
+# openstack-nova-console  OpenStack Nova Console Auth Proxy
+#
+# chkconfig:   - 98 02
+# description: OpenStack Nova Console Auth Proxy Server
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova Console Auth Proxy
+# Description: OpenStack Nova Console Auth Proxy Server
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=consoleauth
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-$suffix"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --logfile $logfile &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-consoleauth.upstart b/openstack-nova-consoleauth.upstart
new file mode 100644
index 0000000..6e27deb
--- /dev/null
+++ b/openstack-nova-consoleauth.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova VNC console auth Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-consoleauth --logfile /var/log/nova/consoleauth.log" nova
diff --git a/openstack-nova-metadata-api.init b/openstack-nova-metadata-api.init
new file mode 100644
index 0000000..445a45f
--- /dev/null
+++ b/openstack-nova-metadata-api.init
@@ -0,0 +1,102 @@
+#!/bin/sh
+#
+# openstack-nova-metadata-api  OpenStack Nova Metadata API Server
+#
+# chkconfig:   - 98 02
+# description: Metadata provider for guests
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova Metadata API Server
+# Description: OpenStack Nova Metadata API Server
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=metadata-api
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-api-metadata"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --logfile $logfile &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-metadata-api.upstart b/openstack-nova-metadata-api.upstart
new file mode 100644
index 0000000..62f953a
--- /dev/null
+++ b/openstack-nova-metadata-api.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova Metadata API Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-api-metadata --logfile /var/log/nova/metadata-api.log" nova
diff --git a/openstack-nova-network.init b/openstack-nova-network.init
new file mode 100644
index 0000000..fe9ed45
--- /dev/null
+++ b/openstack-nova-network.init
@@ -0,0 +1,116 @@
+#!/bin/sh
+#
+# openstack-nova-network  OpenStack Nova Network Controller
+#
+# chkconfig:   - 98 02
+# description: The Network Controller manages the networking resources \
+#              on host machines. The API server dispatches commands    \
+#              through the message queue, which are subsequently       \
+#              processed by Network Controllers.                       \
+#              Specific operations include:                            \
+#              * Allocate Fixed IP Addresses                           \
+#              * Configuring VLANs for projects                        \
+#              * Configuring networks for compute nodes                \
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova Network Controller
+# Description: The Network Controller manages the networking resources
+#              on host machines. The API server dispatches commands
+#              through the message queue, which are subsequently
+#              processed by Network Controllers.
+#              Specific operations include:
+#              * Allocate Fixed IP Addresses
+#              * Configuring VLANs for projects
+#              * Configuring networks for compute nodes
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=network
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-$suffix"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --logfile $logfile &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-network.upstart b/openstack-nova-network.upstart
new file mode 100644
index 0000000..1428bee
--- /dev/null
+++ b/openstack-nova-network.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova Network Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-network --logfile /var/log/nova/network.log" nova
diff --git a/openstack-nova-novncproxy.init b/openstack-nova-novncproxy.init
new file mode 100644
index 0000000..e71400c
--- /dev/null
+++ b/openstack-nova-novncproxy.init
@@ -0,0 +1,102 @@
+#!/bin/sh
+#
+# openstack-nova-novncproxy  OpenStack Nova Console noVNC Proxy
+#
+# chkconfig:   - 98 02
+# description: OpenStack Nova Console noVNC Proxy Server
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova Console noVNC Proxy
+# Description: OpenStack Nova Console noVNC Proxy Server
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=novncproxy
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-$suffix"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --web /usr/share/novnc/ ${OPTIONS} &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-novncproxy.upstart b/openstack-nova-novncproxy.upstart
new file mode 100644
index 0000000..2ea095d
--- /dev/null
+++ b/openstack-nova-novncproxy.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova NoVNCP roxy Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-novncproxy --web /usr/share/novnc" nova
diff --git a/openstack-nova-objectstore.init b/openstack-nova-objectstore.init
new file mode 100644
index 0000000..fafedba
--- /dev/null
+++ b/openstack-nova-objectstore.init
@@ -0,0 +1,102 @@
+#!/bin/sh
+#
+# openstack-nova-objectstore  OpenStack Nova Object Storage
+#
+# chkconfig:   - 98 02
+# description: Implementation of an S3-like storage server based on local files.
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova Object Storage
+# Description: Implementation of an S3-like storage server based on local files.
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=objectstore
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-$suffix"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --logfile $logfile &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-objectstore.upstart b/openstack-nova-objectstore.upstart
new file mode 100644
index 0000000..322c1c5
--- /dev/null
+++ b/openstack-nova-objectstore.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova Objectstore Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-objectstore --logfile /var/log/nova/objectstore.log" nova
diff --git a/openstack-nova-scheduler.init b/openstack-nova-scheduler.init
new file mode 100644
index 0000000..dd45c5d
--- /dev/null
+++ b/openstack-nova-scheduler.init
@@ -0,0 +1,102 @@
+#!/bin/sh
+#
+# openstack-nova-scheduler  OpenStack Nova Scheduler
+#
+# chkconfig:   - 98 02
+# description: Determines which physical hardware to allocate to a virtual resource
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova Scheduler
+# Description: Determines which physical hardware to allocate to a virtual resource
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=scheduler
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-$suffix"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --logfile $logfile &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-scheduler.upstart b/openstack-nova-scheduler.upstart
new file mode 100644
index 0000000..75bef56
--- /dev/null
+++ b/openstack-nova-scheduler.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova Scheduler Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-scheduler --logfile /var/log/nova/scheduler.log" nova
diff --git a/openstack-nova-serialproxy.init b/openstack-nova-serialproxy.init
new file mode 100644
index 0000000..a12af47
--- /dev/null
+++ b/openstack-nova-serialproxy.init
@@ -0,0 +1,102 @@
+#!/bin/sh
+#
+# openstack-nova-novncproxy  OpenStack Nova Console noVNC Proxy
+#
+# chkconfig:   - 98 02
+# description: OpenStack Nova Console noVNC Proxy Server
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova Console noVNC Proxy
+# Description: OpenStack Nova Console noVNC Proxy Server
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=serialproxy
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-$suffix"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --web /usr/share/novnc/ ${OPTIONS} &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-serialproxy.upstart b/openstack-nova-serialproxy.upstart
new file mode 100644
index 0000000..ae52fc1
--- /dev/null
+++ b/openstack-nova-serialproxy.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova Serial Proxy Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-serialproxy" nova
diff --git a/openstack-nova-spicehtml5proxy.init b/openstack-nova-spicehtml5proxy.init
new file mode 100644
index 0000000..18a644b
--- /dev/null
+++ b/openstack-nova-spicehtml5proxy.init
@@ -0,0 +1,102 @@
+#!/bin/sh
+#
+# openstack-nova-spicehtml5proxy  OpenStack Nova Spice HTML5 Proxy
+#
+# chkconfig:   - 98 02
+# description: OpenStack Nova Spice HTML5 Proxy Server
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova Spice HTML5 Proxy
+# Description: OpenStack Nova Spice HTML5 Server
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=spicehtml5proxy
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-$suffix"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --logfile $logfile &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-spicehtml5proxy.upstart b/openstack-nova-spicehtml5proxy.upstart
new file mode 100644
index 0000000..9f02da1
--- /dev/null
+++ b/openstack-nova-spicehtml5proxy.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova Spice HTML5 proxy Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-spicehtml5proxy --logfile /var/log/nova/spicehtml5proxy.log" nova
diff --git a/openstack-nova-xvpvncproxy.init b/openstack-nova-xvpvncproxy.init
new file mode 100644
index 0000000..88affe4
--- /dev/null
+++ b/openstack-nova-xvpvncproxy.init
@@ -0,0 +1,102 @@
+#!/bin/sh
+#
+# openstack-nova-xvpvncproxy  OpenStack Nova Console XVP VNC Proxy
+#
+# chkconfig:   - 98 02
+# description: OpenStack Nova Console XVP VNC Proxy Server
+
+### BEGIN INIT INFO
+# Provides:
+# Required-Start: $remote_fs $network $syslog
+# Required-Stop: $remote_fs $syslog
+# Default-Stop: 0 1 6
+# Short-Description: OpenStack Nova Console XVP VNC Proxy
+# Description: OpenStack Nova Console XVP VNC Proxy Server
+### END INIT INFO
+
+. /etc/rc.d/init.d/functions
+
+suffix=xvpvncproxy
+prog=openstack-nova-$suffix
+exec="/usr/bin/nova-$suffix"
+config="/etc/nova/nova.conf"
+pidfile="/var/run/nova/nova-$suffix.pid"
+logfile="/var/log/nova/$suffix.log"
+
+[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
+
+lockfile=/var/lock/subsys/$prog
+
+start() {
+    [ -x $exec ] || exit 5
+    [ -f $config ] || exit 6
+    echo -n $"Starting $prog: "
+    daemon --user nova --pidfile $pidfile "$exec --logfile $logfile &>/dev/null & echo \$! > $pidfile"
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && touch $lockfile
+    return $retval
+}
+
+stop() {
+    echo -n $"Stopping $prog: "
+    killproc -p $pidfile $prog
+    retval=$?
+    echo
+    [ $retval -eq 0 ] && rm -f $lockfile
+    return $retval
+}
+
+restart() {
+    stop
+    start
+}
+
+reload() {
+    restart
+}
+
+force_reload() {
+    restart
+}
+
+rh_status() {
+    status -p $pidfile $prog
+}
+
+rh_status_q() {
+    rh_status >/dev/null 2>&1
+}
+
+
+case "$1" in
+    start)
+        rh_status_q && exit 0
+        $1
+        ;;
+    stop)
+        rh_status_q || exit 0
+        $1
+        ;;
+    restart)
+        $1
+        ;;
+    reload)
+        rh_status_q || exit 7
+        $1
+        ;;
+    force-reload)
+        force_reload
+        ;;
+    status)
+        rh_status
+        ;;
+    condrestart|try-restart)
+        rh_status_q || exit 0
+        restart
+        ;;
+    *)
+        echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
+        exit 2
+esac
+exit $?
diff --git a/openstack-nova-xvpvncproxy.upstart b/openstack-nova-xvpvncproxy.upstart
new file mode 100644
index 0000000..a004b2a
--- /dev/null
+++ b/openstack-nova-xvpvncproxy.upstart
@@ -0,0 +1,8 @@
+description "OpenStack Nova XVP VncProxy Server"
+
+start on stopped rc RUNLEVEL=[2345]
+stop on runlevel [S016]
+
+respawn
+
+exec su -s /bin/sh -c "exec /usr/bin/nova-xvpvncproxy --logfile /var/log/nova/xvpvncproxy.log" nova
diff --git a/openstack-nova.spec b/openstack-nova.spec
index 5373684..d70fc57 100644
--- a/openstack-nova.spec
+++ b/openstack-nova.spec
@@ -6,7 +6,7 @@
 
 Name:             openstack-nova
 Version:          2014.2.2
-Release:          1%{?dist}
+Release:          2%{?dist}
 Summary:          OpenStack Compute (nova)
 
 Group:            Applications/System
@@ -21,6 +21,38 @@ Source1:          nova-dist.conf
 Source2:          nova.conf.sample
 Source6:          nova.logrotate
 
+%if 0%{?rhel} && 0%{?rhel} <= 6
+Source10:         openstack-nova-api.init
+Source100:        openstack-nova-api.upstart
+Source11:         openstack-nova-cert.init
+Source110:        openstack-nova-cert.upstart
+Source12:         openstack-nova-compute.init
+Source120:        openstack-nova-compute.upstart
+Source13:         openstack-nova-network.init
+Source130:        openstack-nova-network.upstart
+Source14:         openstack-nova-objectstore.init
+Source140:        openstack-nova-objectstore.upstart
+Source15:         openstack-nova-scheduler.init
+Source150:        openstack-nova-scheduler.upstart
+Source16:         openstack-nova-conductor.init
+Source160:        openstack-nova-conductor.upstart
+Source18:         openstack-nova-xvpvncproxy.init
+Source180:        openstack-nova-xvpvncproxy.upstart
+Source19:         openstack-nova-console.init
+Source190:        openstack-nova-console.upstart
+Source24:         openstack-nova-consoleauth.init
+Source240:        openstack-nova-consoleauth.upstart
+Source25:         openstack-nova-metadata-api.init
+Source250:        openstack-nova-metadata-api.upstart
+Source26:         openstack-nova-cells.init
+Source260:        openstack-nova-cells.upstart
+Source27:         openstack-nova-spicehtml5proxy.init
+Source270:        openstack-nova-spicehtml5proxy.upstart
+Source28:         openstack-nova-novncproxy.init
+Source280:        openstack-nova-novncproxy.upstart
+Source29:         openstack-nova-serialproxy.init
+Source290:        openstack-nova-serialproxy.upstart
+%else
 Source10:         openstack-nova-api.service
 Source11:         openstack-nova-cert.service
 Source12:         openstack-nova-compute.service
@@ -36,11 +68,12 @@ Source27:         openstack-nova-cells.service
 Source28:         openstack-nova-spicehtml5proxy.service
 Source29:         openstack-nova-novncproxy.service
 Source31:         openstack-nova-serialproxy.service
+%endif
 
 Source21:         nova-polkit.pkla
 Source23:         nova-polkit.rules
 Source22:         nova-ifc-template
-Source24:         nova-sudoers
+Source32:         nova-sudoers
 Source30:         openstack-nova-novncproxy.sysconfig
 
 BuildArch:        noarch
@@ -88,11 +121,16 @@ Requires:         python-oslo-i18n
 Requires:         python-posix_ipc
 Requires:         python-rfc3986
 
+%if 0%{?rhel} && 0%{?rhel} <= 6
+Requires(postun): initscripts
+Requires(preun):  chkconfig
+%else
 Requires(post):   systemd
 Requires(preun):  systemd
 Requires(postun): systemd
-Requires(pre):    shadow-utils
 BuildRequires:    systemd
+%endif
+Requires(pre):    shadow-utils
 
 %description common
 OpenStack Compute (codename Nova) is open source software designed to
@@ -117,9 +155,19 @@ Requires:         curl
 Requires:         iscsi-initiator-utils
 Requires:         iptables iptables-ipv6
 Requires:         ipmitool
+%if 0%{?rhel} && 0%{?rhel} <= 6
+# import dec failed otherwise
+Requires:         python-webob1.0
+# tunctl is needed where `ip tuntap` is not available
+Requires:         tunctl
+%endif
 Requires:         python-libguestfs
 Requires:         libvirt-python
+%if 0%{?rhel} && 0%{?rhel} <= 6
+Requires:         libvirt >= 0.9.6
+%else
 Requires:         libvirt-daemon-kvm
+%endif
 %if 0%{?rhel}==0
 Requires:         libvirt-daemon-lxc
 Requires:         libvirt-daemon-uml
@@ -154,6 +202,10 @@ Requires:         radvd
 Requires:         bridge-utils
 Requires:         dnsmasq
 Requires:         dnsmasq-utils
+%if 0%{?rhel} && 0%{?rhel} <= 6
+# tunctl is needed where `ip tuntap` is not available
+Requires:         tunctl
+%endif
 Requires:         ebtables
 
 %description network
@@ -545,6 +597,23 @@ package = %{release}
 EOF
 
 # Install initscripts for Nova services
+%if 0%{?rhel} && 0%{?rhel} <= 6
+install -p -D -m 755 %{SOURCE10} %{buildroot}%{_initrddir}/openstack-nova-api
+install -p -D -m 755 %{SOURCE11} %{buildroot}%{_initrddir}/openstack-nova-cert
+install -p -D -m 755 %{SOURCE12} %{buildroot}%{_initrddir}/openstack-nova-compute
+install -p -D -m 755 %{SOURCE13} %{buildroot}%{_initrddir}/openstack-nova-network
+install -p -D -m 755 %{SOURCE14} %{buildroot}%{_initrddir}/openstack-nova-objectstore
+install -p -D -m 755 %{SOURCE15} %{buildroot}%{_initrddir}/openstack-nova-scheduler
+install -p -D -m 755 %{SOURCE16} %{buildroot}%{_initrddir}/openstack-nova-conductor
+install -p -D -m 755 %{SOURCE18} %{buildroot}%{_initrddir}/openstack-nova-xvpvncproxy
+install -p -D -m 755 %{SOURCE19} %{buildroot}%{_initrddir}/openstack-nova-console
+install -p -D -m 755 %{SOURCE24} %{buildroot}%{_initrddir}/openstack-nova-consoleauth
+install -p -D -m 755 %{SOURCE25} %{buildroot}%{_initrddir}/openstack-nova-metadata-api
+install -p -D -m 755 %{SOURCE26} %{buildroot}%{_initrddir}/openstack-nova-cells
+install -p -D -m 755 %{SOURCE27} %{buildroot}%{_initrddir}/openstack-nova-spicehtml5proxy
+install -p -D -m 755 %{SOURCE28} %{buildroot}%{_initrddir}/openstack-nova-novncproxy
+install -p -D -m 755 %{SOURCE29} %{buildroot}%{_initrddir}/openstack-nova-serialproxy
+%else
 install -p -D -m 755 %{SOURCE10} %{buildroot}%{_unitdir}/openstack-nova-api.service
 install -p -D -m 755 %{SOURCE11} %{buildroot}%{_unitdir}/openstack-nova-cert.service
 install -p -D -m 755 %{SOURCE12} %{buildroot}%{_unitdir}/openstack-nova-compute.service
@@ -560,6 +629,7 @@ install -p -D -m 755 %{SOURCE27} %{buildroot}%{_unitdir}/openstack-nova-cells.se
 install -p -D -m 755 %{SOURCE28} %{buildroot}%{_unitdir}/openstack-nova-spicehtml5proxy.service
 install -p -D -m 755 %{SOURCE29} %{buildroot}%{_unitdir}/openstack-nova-novncproxy.service
 install -p -D -m 755 %{SOURCE31} %{buildroot}%{_unitdir}/openstack-nova-serialproxy.service
+%endif
 
 # Install sudoers
 install -p -D -m 440 %{SOURCE24} %{buildroot}%{_sysconfdir}/sudoers.d/nova
@@ -574,6 +644,25 @@ install -d -m 755 %{buildroot}%{_localstatedir}/run/nova
 install -p -D -m 644 nova/cloudpipe/client.ovpn.template %{buildroot}%{_datarootdir}/nova/client.ovpn.template
 install -p -D -m 644 %{SOURCE22} %{buildroot}%{_datarootdir}/nova/interfaces.template
 
+%if 0%{?rhel} && 0%{?rhel} <= 6
+# Install upstart jobs examples
+install -p -m 644 %{SOURCE100} %{buildroot}%{_datadir}/nova/
+install -p -m 644 %{SOURCE110} %{buildroot}%{_datadir}/nova/
+install -p -m 644 %{SOURCE120} %{buildroot}%{_datadir}/nova/
+install -p -m 644 %{SOURCE130} %{buildroot}%{_datadir}/nova/
+install -p -m 644 %{SOURCE140} %{buildroot}%{_datadir}/nova/
+install -p -m 644 %{SOURCE150} %{buildroot}%{_datadir}/nova/
+install -p -m 644 %{SOURCE160} %{buildroot}%{_datadir}/nova/
+install -p -m 644 %{SOURCE180} %{buildroot}%{_datadir}/nova/
+install -p -m 644 %{SOURCE190} %{buildroot}%{_datadir}/nova/
+install -p -m 644 %{SOURCE240} %{buildroot}%{_datadir}/nova/
+install -p -m 644 %{SOURCE250} %{buildroot}%{_datadir}/nova/
+install -p -m 644 %{SOURCE260} %{buildroot}%{_datadir}/nova/
+install -p -m 644 %{SOURCE270} %{buildroot}%{_datadir}/nova/
+install -p -m 644 %{SOURCE280} %{buildroot}%{_datadir}/nova/
+install -p -m 644 %{SOURCE290} %{buildroot}%{_datadir}/nova/
+%endif
+
 # Install rootwrap files in /usr/share/nova/rootwrap
 mkdir -p %{buildroot}%{_datarootdir}/nova/rootwrap/
 install -p -D -m 644 etc/nova/rootwrap.d/* %{buildroot}%{_datarootdir}/nova/rootwrap/
@@ -608,79 +697,370 @@ usermod -a -G qemu nova
 exit 0
 
 %post compute
+%if 0%{?rhel} && 0%{?rhel} <= 6
+/sbin/chkconfig --add %{name}-compute
+%else
 %systemd_post %{name}-compute.service
+%endif
+
 %post network
+%if 0%{?rhel} && 0%{?rhel} <= 6
+/sbin/chkconfig --add %{name}-network
+%else
 %systemd_post %{name}-network.service
+%endif
+
 %post scheduler
+%if 0%{?rhel} && 0%{?rhel} <= 6
+/sbin/chkconfig --add %{name}-scheduler
+%else
 %systemd_post %{name}-scheduler.service
+%endif
+
 %post cert
+%if 0%{?rhel} && 0%{?rhel} <= 6
+/sbin/chkconfig --add %{name}-cert
+%else
 %systemd_post %{name}-cert.service
+%endif
+
 %post api
+%if 0%{?rhel} && 0%{?rhel} <= 6
+for svc in api metadata-api; do
+    /sbin/chkconfig --add %{name}-$svc
+done
+%else
 %systemd_post %{name}-api.service %{name}-metadata-api.service
+%endif
+
 %post conductor
+%if 0%{?rhel} && 0%{?rhel} <= 6
+/sbin/chkconfig --add %{name}-conductor
+%else
 %systemd_post %{name}-conductor.service
+%endif
+
 %post objectstore
+%if 0%{?rhel} && 0%{?rhel} <= 6
+/sbin/chkconfig --add %{name}-objectstore
+%else
 %systemd_post %{name}-objectstore.service
+%endif
+
 %post console
+%if 0%{?rhel} && 0%{?rhel} <= 6
+for svc in console consoleauth xvpvncproxy spicehtml5proxy; do
+    /sbin/chkconfig --add %{name}-$svc
+done
+%else
 %systemd_post %{name}-console.service %{name}-consoleauth.service %{name}-xvpvncproxy.service
+%endif
+
 %post cells
+%if 0%{?rhel} && 0%{?rhel} <= 6
+/sbin/chkconfig --add %{name}-cells
+%else
 %systemd_post %{name}-cells.service
+%endif
+
 %post novncproxy
+%if 0%{?rhel} && 0%{?rhel} <= 6
+/sbin/chkconfig --add %{name}-novncproxy
+%else
 %systemd_post %{name}-novncproxy.service
+%endif
+
 %post spicehtml5proxy
+%if 0%{?rhel} && 0%{?rhel} <= 6
+/sbin/chkconfig --add %{name}-spicehtml5proxy
+%else
 %systemd_post %{name}-spicehtml5proxy.service
+%endif
+
 %post serialproxy
+%if 0%{?rhel} && 0%{?rhel} <= 6
+/sbin/chkconfig --add %{name}-serialproxy
+%else
 %systemd_post %{name}-serialproxy.service
+%endif
 
 %preun compute
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -eq 0 ] ; then
+    for svc in compute; do
+        /sbin/service %{name}-${svc} stop >/dev/null 2>&1
+        /sbin/chkconfig --del %{name}-${svc}
+    done
+fi
+%else
 %systemd_preun %{name}-compute.service
+%endif
+
 %preun network
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -eq 0 ] ; then
+    for svc in network; do
+        /sbin/service %{name}-${svc} stop >/dev/null 2>&1
+        /sbin/chkconfig --del %{name}-${svc}
+    done
+fi
+%else
 %systemd_preun %{name}-network.service
+%endif
+
 %preun scheduler
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -eq 0 ] ; then
+    for svc in scheduler; do
+        /sbin/service %{name}-${svc} stop >/dev/null 2>&1
+        /sbin/chkconfig --del %{name}-${svc}
+    done
+fi
+%else
 %systemd_preun %{name}-scheduler.service
+%endif
+
 %preun cert
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -eq 0 ] ; then
+    for svc in cert; do
+        /sbin/service %{name}-${svc} stop >/dev/null 2>&1
+        /sbin/chkconfig --del %{name}-${svc}
+    done
+fi
+%else
 %systemd_preun %{name}-cert.service
+%endif
+
 %preun api
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -eq 0 ] ; then
+    for svc in api metadata-api; do
+        /sbin/service %{name}-${svc} stop >/dev/null 2>&1
+        /sbin/chkconfig --del %{name}-${svc}
+    done
+fi
+%else
 %systemd_preun %{name}-api.service %{name}-metadata-api.service
+%endif
+
 %preun objectstore
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -eq 0 ] ; then
+    for svc in objectstore; do
+        /sbin/service %{name}-${svc} stop >/dev/null 2>&1
+        /sbin/chkconfig --del %{name}-${svc}
+    done
+fi
+%else
 %systemd_preun %{name}-objectstore.service
+%endif
+
 %preun conductor
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -eq 0 ] ; then
+    for svc in conductor; do
+        /sbin/service %{name}-${svc} stop >/dev/null 2>&1
+        /sbin/chkconfig --del %{name}-${svc}
+    done
+fi
+%else
 %systemd_preun %{name}-conductor.service
+%endif
+
 %preun console
 %systemd_preun %{name}-console.service %{name}-consoleauth.service %{name}-xvpvncproxy.service
 %preun cells
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -eq 0 ] ; then
+    for svc in cells; do
+        /sbin/service %{name}-${svc} stop >/dev/null 2>&1
+        /sbin/chkconfig --del %{name}-${svc}
+    done
+fi
+%else
 %systemd_preun %{name}-cells.service
+%endif
+
 %preun novncproxy
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -eq 0 ] ; then
+    for svc in novncproxy; do
+        /sbin/service %{name}-${svc} stop >/dev/null 2>&1
+        /sbin/chkconfig --del %{name}-${svc}
+    done
+fi
+%else
 %systemd_preun %{name}-novncproxy.service
+%endif
+
 %preun spicehtml5proxy
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -eq 0 ] ; then
+    for svc in spicehtml5proxy; do
+        /sbin/service %{name}-${svc} stop >/dev/null 2>&1
+        /sbin/chkconfig --del %{name}-${svc}
+    done
+fi
+%else
 %systemd_preun %{name}-spicehtml5proxy.service
+%endif
+
 %preun serialproxy
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -eq 0 ] ; then
+    for svc in serialproxy; do
+        /sbin/service %{name}-${svc} stop >/dev/null 2>&1
+        /sbin/chkconfig --del %{name}-${svc}
+    done
+fi
+%else
 %systemd_preun %{name}-serialproxy.service
+%endif
 
 %postun compute
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -ge 1 ] ; then
+    # package upgrade, not uninstall
+    for svc in compute; do
+        /sbin/service %{name}-${svc} condrestart > /dev/null 2>&1 || :
+    done
+fi
+%else
 %systemd_postun_with_restart %{name}-compute.service
+%endif
+
 %postun network
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -ge 1 ] ; then
+    # package upgrade, not uninstall
+    for svc in network; do
+        /sbin/service %{name}-${svc} condrestart > /dev/null 2>&1 || :
+    done
+fi
+%else
 %systemd_postun_with_restart %{name}-network.service
+%endif
+
 %postun scheduler
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -ge 1 ] ; then
+    # package upgrade, not uninstall
+    for svc in scheduler; do
+        /sbin/service %{name}-${svc} condrestart > /dev/null 2>&1 || :
+    done
+fi
+%else
 %systemd_postun_with_restart %{name}-scheduler.service
+%endif
+
 %postun cert
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -ge 1 ] ; then
+    # package upgrade, not uninstall
+    for svc in cert; do
+        /sbin/service %{name}-${svc} condrestart > /dev/null 2>&1 || :
+    done
+fi
+%else
 %systemd_postun_with_restart %{name}-cert.service
+%endif
+
 %postun api
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -ge 1 ] ; then
+    # package upgrade, not uninstall
+    for svc in api metadata-api; do
+        /sbin/service %{name}-${svc} condrestart > /dev/null 2>&1 || :
+    done
+fi
+%else
 %systemd_postun_with_restart %{name}-api.service %{name}-metadata-api.service
+%endif
+
 %postun objectstore
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -ge 1 ] ; then
+    # package upgrade, not uninstall
+    for svc in objectstore; do
+        /sbin/service %{name}-${svc} condrestart > /dev/null 2>&1 || :
+    done
+fi
+%else
 %systemd_postun_with_restart %{name}-objectstore.service
+%endif
+
 %postun conductor
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -ge 1 ] ; then
+    # package upgrade, not uninstall
+    for svc in conductor; do
+        /sbin/service %{name}-${svc} condrestart > /dev/null 2>&1 || :
+    done
+fi
+%else
 %systemd_postun_with_restart %{name}-conductor.service
+%endif
+
 %postun console
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -ge 1 ] ; then
+    # package upgrade, not uninstall
+    for svc in console consoleauth xvpvncproxy spicehtml5proxy; do
+        /sbin/service %{name}-${svc} condrestart > /dev/null 2>&1 || :
+    done
+fi
+%else
 %systemd_postun_with_restart %{name}-console.service %{name}-consoleauth.service %{name}-xvpvncproxy.service
+%endif
+
 %postun cells
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -ge 1 ] ; then
+    # package upgrade, not uninstall
+    for svc in cells; do
+        /sbin/service %{name}-${svc} condrestart > /dev/null 2>&1 || :
+    done
+fi
+%else
 %systemd_postun_with_restart %{name}-cells.service
+%endif
+
 %postun novncproxy
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -ge 1 ] ; then
+    # package upgrade, not uninstall
+    for svc in novncproxy; do
+        /sbin/service %{name}-${svc} condrestart > /dev/null 2>&1 || :
+    done
+fi
+%else
 %systemd_postun_with_restart %{name}-novncproxy.service
+%endif
+
 %postun spicehtml5proxy
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -ge 1 ] ; then
+    # package upgrade, not uninstall
+    for svc in spicehtml5proxy; do
+        /sbin/service %{name}-${svc} condrestart > /dev/null 2>&1 || :
+    done
+fi
+%else
 %systemd_postun_with_restart %{name}-spicehtml5proxy.service
+%endif
+
 %postun serialproxy
+%if 0%{?rhel} && 0%{?rhel} <= 6
+if [ $1 -ge 1 ] ; then
+    # package upgrade, not uninstall
+    for svc in serialproxy; do
+        /sbin/service %{name}-${svc} condrestart > /dev/null 2>&1 || :
+    done
+fi
+%else
 %systemd_postun_with_restart %{name}-serialproxy.service
+%endif
 
 %files
 %doc LICENSE
@@ -706,6 +1086,7 @@ exit 0
 %{_bindir}/nova-manage
 %{_bindir}/nova-rootwrap
 
+%exclude %{_datarootdir}/nova/*.upstart
 %{_datarootdir}/nova
 %{_mandir}/man1/nova*.1.gz
 
@@ -722,22 +1103,42 @@ exit 0
 %{_bindir}/nova-baremetal-deploy-helper
 %{_bindir}/nova-baremetal-manage
 %{_bindir}/nova-idmapshift
+%if 0%{?rhel} && 0%{?rhel} <= 6
+%{_initrddir}/openstack-nova-compute
+%{_datarootdir}/nova/openstack-nova-compute.upstart
+%else
 %{_unitdir}/openstack-nova-compute.service
+%endif
 %{_datarootdir}/nova/rootwrap/compute.filters
 
 %files network
 %{_bindir}/nova-network
 %{_bindir}/nova-dhcpbridge
+%if 0%{?rhel} && 0%{?rhel} <= 6
+%{_initrddir}/openstack-nova-network
+%{_datarootdir}/nova/openstack-nova-network.upstart
+%else
 %{_unitdir}/openstack-nova-network.service
+%endif
 %{_datarootdir}/nova/rootwrap/network.filters
 
 %files scheduler
 %{_bindir}/nova-scheduler
+%if 0%{?rhel} && 0%{?rhel} <= 6
+%{_initrddir}/openstack-nova-scheduler
+%{_datarootdir}/nova/openstack-nova-scheduler.upstart
+%else
 %{_unitdir}/openstack-nova-scheduler.service
+%endif
 
 %files cert
 %{_bindir}/nova-cert
+%if 0%{?rhel} && 0%{?rhel} <= 6
+%{_initrddir}/openstack-nova-cert
+%{_datarootdir}/nova/openstack-nova-cert.upstart
+%else
 %{_unitdir}/openstack-nova-cert.service
+%endif
 %defattr(-, nova, nova, -)
 %dir %{_sharedstatedir}/nova/CA/
 %dir %{_sharedstatedir}/nova/CA/certs
@@ -757,39 +1158,86 @@ exit 0
 
 %files api
 %{_bindir}/nova-api*
+%if 0%{?rhel} && 0%{?rhel} <= 6
+%{_initrddir}/openstack-nova-*api
+%{_datarootdir}/nova/openstack-nova-*api.upstart
+%else
 %{_unitdir}/openstack-nova-*api.service
+%endif
 %{_datarootdir}/nova/rootwrap/api-metadata.filters
 
 %files conductor
 %{_bindir}/nova-conductor
+%if 0%{?rhel} && 0%{?rhel} <= 6
+%{_initrddir}/openstack-nova-conductor
+%{_datarootdir}/nova/openstack-nova-conductor.upstart
+%else
 %{_unitdir}/openstack-nova-conductor.service
+%endif
 
 %files objectstore
 %{_bindir}/nova-objectstore
+%if 0%{?rhel} && 0%{?rhel} <= 6
+%{_initrddir}/openstack-nova-objectstore
+%{_datarootdir}/nova/openstack-nova-objectstore.upstart
+%else
 %{_unitdir}/openstack-nova-objectstore.service
+%endif
 
 %files console
 %{_bindir}/nova-console*
 %{_bindir}/nova-xvpvncproxy
+%{_bindir}/nova-spicehtml5proxy
+%if 0%{?rhel} && 0%{?rhel} <= 6
+%{_initrddir}/openstack-nova-console*
+%{_datarootdir}/nova/openstack-nova-console*.upstart
+%{_initrddir}/openstack-nova-xvpvncproxy
+%{_datarootdir}/nova/openstack-nova-xvpvncproxy.upstart
+%{_initrddir}/openstack-nova-spicehtml5proxy*
+%{_datarootdir}/nova/openstack-nova-spicehtml5proxy.upstart
+%else
 %{_unitdir}/openstack-nova-console*.service
 %{_unitdir}/openstack-nova-xvpvncproxy.service
+%{_unitdir}/openstack-nova-spicehtml5proxy.service
+%endif
 
 %files cells
 %{_bindir}/nova-cells
+%if 0%{?rhel} && 0%{?rhel} <= 6
+%{_initrddir}/openstack-nova-cells
+%{_datarootdir}/nova/openstack-nova-cells.upstart
+%else
 %{_unitdir}/openstack-nova-cells.service
+%endif
 
 %files novncproxy
 %{_bindir}/nova-novncproxy
+%if 0%{?rhel} && 0%{?rhel} <= 6
+%{_initrddir}/openstack-nova-novncproxy
+%{_datarootdir}/nova/openstack-nova-novncproxy.upstart
+%else
 %{_unitdir}/openstack-nova-novncproxy.service
+%endif
+
 %config(noreplace) %{_sysconfdir}/sysconfig/openstack-nova-novncproxy
 
 %files spicehtml5proxy
 %{_bindir}/nova-spicehtml5proxy
+%if 0%{?rhel} && 0%{?rhel} <= 6
+%{_initrddir}/openstack-nova-spicehtml5proxy
+%{_datarootdir}/nova/openstack-nova-spicehtml5proxy.upstart
+%else
 %{_unitdir}/openstack-nova-spicehtml5proxy.service
+%endif
 
 %files serialproxy
 %{_bindir}/nova-serialproxy
+%if 0%{?rhel} && 0%{?rhel} <= 6
+%{_initrddir}/openstack-nova-serialproxy
+%{_datarootdir}/nova/openstack-nova-serialproxy.upstart
+%else
 %{_unitdir}/openstack-nova-serialproxy.service
+%endif
 
 %files -n python-nova
 %defattr(-,root,root,-)
@@ -803,6 +1251,10 @@ exit 0
 %endif
 
 %changelog
+* Mon Mar 09 2015 Thomas Oulevey <thomas oulevey cern ch> 2014.2.2-2
+- Adapt spec file for juno el6
+- Add *init and *upstart
+
 * Wed Feb 11 2015 Alan Pevec <alan pevec redhat com> 2014.2.2-1
 - Update to upstream 2014.2.2
 
-- 
1.7.1


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]