Skip to content
Snippets Groups Projects
Commit d8818121 authored by Antoine Millet's avatar Antoine Millet
Browse files

Removed debian packaging from upstream repository

parent 4cf6eaa5
No related branches found
No related tags found
No related merge requests found
# /etc/default/cc-node
# CloudControl node daemon options
# Set to true to enable the cc-node daemon
ENABLED=true
/var/lib/cc-node/jobs
#! /bin/sh
### BEGIN INIT INFO
# Provides: cc-node
# Required-Start: $local_fs $remote_fs $network $syslog
# Required-Stop: $local_fs $remote_fs $network $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: start the CloudControl node
# Description: starts the CloudControl node using start-stop-daemon
### END INIT INFO
# Author: Antoine Millet <antoine.millet@smartjog.com>
# Thibault VINCENT <thibault.vincent@smartjog.com>
PATH=/sbin:/usr/sbin:/bin:/usr/bin
DESC="CloudControl node"
NAME=cc-node
DAEMON=/usr/bin/cc-node
PIDFILE=/var/run/$NAME.pid
DAEMON_OPTS="-d -p $PIDFILE"
# Defaults:
USER=root
GROUP=root
# Exit if the package is not installed
[ -x "$DAEMON" ] || exit 0
# Load various rcS variables
. /lib/init/vars.sh
# Override the VERBOSE variable so we always have feedback messages
VERBOSE=yes
# Define LSB log_* functions.
# Depend on lsb-base (>= 3.2-14) to ensure that this file is present
# and status_of_proc is working.
. /lib/lsb/init-functions
# Read and parse configuration variable file if it is present
[ -r /etc/default/$NAME ] && {
. /etc/default/$NAME
# Do not start if service is disabled
if [ "$ENABLED" != "true" ] ; then
echo "$DESC disabled, see /etc/default/$NAME"
exit 0
fi
}
#
# Function that starts the daemon/service
#
do_start()
{
start-stop-daemon --start --quiet --name $NAME --test \
--exec $(readlink -f $(which python)) > /dev/null || return 2
start-stop-daemon --start --quiet --pidfile $PIDFILE --chuid $USER:$GROUP \
--exec $DAEMON -- $DAEMON_OPTS || return 1
}
#
# Function that stops the daemon/service
#
do_stop()
{
start-stop-daemon --stop --quiet --retry=TERM/30/KILL/5 \
--pidfile $PIDFILE --name $NAME
RETVAL="$?"
[ "$RETVAL" = 2 ] && return 2
# Wait for children to finish too if this is a daemon that forks
# and if the daemon is only ever run from this initscript.
# If the above conditions are not satisfied then add some other code
# that waits for the process to drop all resources that could be
# needed by services started subsequently. A last resort is to
# sleep for some time.
start-stop-daemon --stop --quiet --oknodo --retry=0/30/KILL/5 \
--exec $DAEMON
[ "$?" = 2 ] && return 2
# Many daemons don't delete their pidfiles when they exit.
rm -f $PIDFILE
return "$RETVAL"
}
#
# Function that sends a SIGHUP to the daemon/service
#
do_reload() {
start-stop-daemon --stop --signal 1 --quiet --pidfile $PIDFILE \
--name $NAME
return 0
}
case "$1" in
start)
[ "$VERBOSE" != no ] && log_daemon_msg "Starting $DESC" "$NAME"
do_start
case "$?" in
0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;;
2) [ "$VERBOSE" != no ] && log_end_msg 1 ;;
esac
;;
stop)
[ "$VERBOSE" != no ] && log_daemon_msg "Stopping $DESC" "$NAME"
do_stop
case "$?" in
0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;;
2) [ "$VERBOSE" != no ] && log_end_msg 1 ;;
esac
;;
status)
status_of_proc "$DAEMON" "$NAME" && exit 0 || exit $?
;;
restart|force-reload)
#
# If the "reload" option is implemented then remove the
# 'force-reload' alias
#
[ "$VERBOSE" != no ] && log_daemon_msg "Restarting $DESC" "$NAME"
do_stop
case "$?" in
0|1)
do_start
case "$?" in
0) [ "$VERBOSE" != no ] && log_end_msg 0 ;;
1) [ "$VERBOSE" != no ] && log_end_msg 1 ;; # Old process is still running
*) [ "$VERBOSE" != no ] && log_end_msg 1 ;; # Failed to start
esac
;;
*)
# Failed to stop
[ "$VERBOSE" != no ] && log_end_msg 1
;;
esac
;;
*)
echo "Usage: $SCRIPTNAME {start|stop|status|restart|force-reload}" >&2
exit 3
;;
esac
:
usr/lib/python2.*/*/cloudcontrol/node
usr/lib/python2.*/*/cc_node-*
usr/bin/cc-node
etc/cc-node.conf
#!/bin/sh
set -e
CONF="/etc/cc-node.conf"
if [ -f "$CONF" ]; then
# secure the config file
chmod 0640 "$CONF"
# replace login by hostname if unset
if grep '\$\$LOGIN\$\$' "$CONF" >/dev/null; then
login=$(hostname)
echo "*** CC-Node login : ${login}"
sed -e "s/\\\$\\\$LOGIN\\\$\\\$/${login}/g" -i "$CONF"
fi
# generate a random password if unset
if grep '\$\$PASSWORD\$\$' "$CONF" >/dev/null; then
password=$(cat /dev/urandom | tr -dc A-Za-z0-9 | head -c 12)
echo "*** CC-Node password : ${password}"
sed -e "s/\\\$\\\$PASSWORD\\\$\\\$/${password}/g"\
-i "$CONF"
fi
fi
# hardcode debhelpers to start the daemon after pycentral
# Automatically added by dh_pycentral
rm -f /var/lib/pycentral/cc-node.pkgremove
if which pycentral >/dev/null 2>&1; then
pycentral pkginstall cc-node
if grep -qs '^cc-node$' /var/lib/pycentral/delayed-pkgs; then
sed -i '/^cc-node$/d' /var/lib/pycentral/delayed-pkgs
fi
fi
# End automatically added section
# Workaround to restart node after pycentral
if [ -x "/etc/init.d/cc-node" ]; then
update-rc.d cc-node defaults >/dev/null
if [ -x "`which invoke-rc.d 2>/dev/null`" ]; then
invoke-rc.d cc-node start || exit $?
else
/etc/init.d/cc-node start || exit $?
fi
fi
exit 0
cc-node (27) UNRELEASED; urgency=low
* Fix missing decorator for tun_setup handler
* Fix hypervisor handler initialization
-- Anaël Beutot <anael.beutot@smartjog.com> Wed, 27 Mar 2013 16:12:36 +0100
cc-node (26) unstable; urgency=low
* Updated dependency on cc-common
-- Anaël Beutot <anael.beutot@smartjog.com> Mon, 18 Mar 2013 16:28:48 +0100
cc-node (25) unstable; urgency=low
* New upstream release
* Fix set literal usage for python < 2.7
-- Anaël Beutot <anael.beutot@smartjog.com> Wed, 27 Feb 2013 14:18:07 +0100
cc-node (24) unstable; urgency=low
* New upstream release
* Added permission for RPC handlers
* Fix bug when domain is updated while running, when restarted, update
informations about the domain
* Added back option to disallow remote execution
-- Anaël Beutot <anael.beutot@smartjog.com> Wed, 27 Feb 2013 13:53:56 +0100
cc-node (23) unstable; urgency=low
* Update dependency on cc-common version 5
* Fix network interface list on VMs
* Fix some errors with invalid plugins persistence file
* Fix sto_vol tag conflict when libvirt connection is lost
-- Anaël Beutot <anael.beutot@smartjog.com> Mon, 17 Dec 2012 14:38:34 +0100
cc-node (22) unstable; urgency=low
* Update dependency on cc-common version 3
* Added tags: membuffers, memcaches, sto_vol
* VMs can be started in pause state
-- Anael Beutot <anael.beutot@smartjog.com> Tue, 20 Nov 2012 16:03:32 +0100
cc-node (21) unstable; urgency=low
* Fix console handler
-- Anael Beutot <anael.beutot@smartjog.com> Tue, 06 Nov 2012 17:22:58 +0100
cc-node (20) unstable; urgency=low
* Fix plugin loading at startup
* Better erorr reporting for remote command execution
* Fix unicode/syslog issue
* Check libvirtd version before opening virtio console
* Updgraded to packaging source format squilt v3.0
* Fix ForkedJob (concerns migrations)
-- Anael Beutot <anael.beutot@smartjog.com> Wed, 24 Oct 2012 17:24:20 +0200
cc-node (19) unstable; urgency=low
* Complete rewrite
* Better libvirt support (0.8.8 to 0.9.12)
* Only KVM support by now
* Remote shell
* Remote console (for VMs)
* Tag registration
* Support for remote script execution
* Support for user defined plugins
-- Anael Beutot <anael.beutot@smartjog.com> Thu, 23 Aug 2012 17:20:46 +0200
cc-node (17) unstable; urgency=low
* Fix running in host mode without python-libvirt
-- Thibault VINCENT <thibault.vincent@smartjog.com> Fri, 24 Jun 2011 11:51:33 +0200
cc-node (16) unstable; urgency=low
* Xen fix
-- Thibault VINCENT <thibault.vincent@smartjog.com> Mon, 06 Jun 2011 11:03:38 +0200
cc-node (15) unstable; urgency=low
* Use Unix socket to bind tunnels to libvirt (default config compliance)
-- Thibault VINCENT <thibault.vincent@smartjog.com> Wed, 01 Jun 2011 16:41:30 +0200
cc-node (14) unstable; urgency=low
* New: live DRBD migration for Xen/KVM
* Fix: various as usual ...
-- Thibault VINCENT <thibault.vincent@smartjog.com> Wed, 01 Jun 2011 11:36:31 +0200
cc-node (11) unstable; urgency=low
* New: cold migration
* New: chassis tag
* New: VNC tag
* Fix: spurious VM unregistration
* Fix: wrong memory reported fow Xen host and Dom0
* Fix: missing storage pool/volume data when value is zero
* Fix: missing Xen VM arch tag
* And other code enhancement
-- Thibault VINCENT <thibault.vincent@smartjog.com> Tue, 08 Mar 2011 17:21:21 +0100
cc-node (10-1) unstable; urgency=low
* Just a new version
-- Thibault VINCENT <thibault.vincent@smartjog.com> Thu, 10 Feb 2011 18:14:22 +0100
cc-node (9) unstable; urgency=low
* Lots of fixes and improvements
* Faster with less contention
* Now returns real TTL, etc...
-- Thibault VINCENT <thibault.vincent@smartjog.com> Thu, 03 Feb 2011 15:11:37 +0100
cc-node (8) unstable; urgency=low
* Huge rewrite of libvirt wrapper and server handler
* Add new hardware-related tags
* Basecode ready for Xen integration
-- Thibault VINCENT <thibault.vincent@smartjog.com> Mon, 10 Jan 2011 18:49:28 +0100
cc-node (7) unstable; urgency=low
* New tags implemented for HV and VM
-- Thibault VINCENT <thibault.vincent@smartjog.com> Thu, 30 Dec 2010 13:28:19 +0100
cc-node (6) unstable; urgency=low
* Bug fix
* Proper release with newer init scripts
-- Thibault VINCENT <tibal@reloaded.fr> Mon, 27 Dec 2010 17:12:40 +0100
cc-node (5-2) unstable; urgency=low
* Fix configuration option for HV detection
-- Thibault VINCENT <tibal@reloaded.fr> Mon, 27 Dec 2010 14:10:52 +0100
cc-node (5-1) unstable; urgency=low
* Support for non-hypervisor nodes
* New tags implemented
* First migration features
-- Thibault VINCENT <tibal@reloaded.fr> Mon, 27 Dec 2010 12:18:42 +0100
cc-node (4-1) unstable; urgency=low
* Fixed bugs
-- Antoine Millet <antoine.millet@smartjog.com> Wed, 22 Dec 2010 17:50:48 +0100
cc-node (3-1) unstable; urgency=low
* Added $HOSTNAME variable on login field of config file.
* Fixed bugs
-- Antoine Millet <antoine.millet@smartjog.com> Wed, 22 Dec 2010 16:47:14 +0100
cc-node (2-1) unstable; urgency=low
* New configuration in configuration file
* Changed name cc-hypervisor to cc-node
* Tags handled in list_vm
-- Antoine Millet <antoine.millet@smartjog.com> Fri, 17 Dec 2010 11:43:42 +0100
cc-node (1-1) unstable; urgency=low
* Initial release.
-- Antoine Millet <antoine.millet@smartjog.com> Mon, 06 Dec 2010 16:42:27 +0100
7
Source: cc-node
Section: python
Priority: optional
Maintainer: Anaël Beutot <anael.beutot@smartjog.com>
Build-Depends: debhelper (>= 7),
python-central (>= 0.6),
cdbs (>= 0.4.50),
python-setuptools,
python
XS-Python-Version: >= 2.6
Standards-Version: 3.9.1
Package: cc-node
Architecture: all
Depends: ${misc:Depends},
${python:Depends},
python-sjrpc ( >= 18 ),
python-psutil,
python-daemon,
cc-common ( >= 6 ),
python-pyev ( >= 0.8.1 )
XB-Python-Version: ${python:Versions}
Description: CloudControl node
This package provides node of CloudControl.
Package: cc-node-hypervisor
Architecture: all
Depends: ${misc:Depends}, cc-node (= ${binary:Version}), python-libvirt, drbd8-utils
Description: CC-node meta package for use with KVM hypervisor.
This package provides node of CloudControl with hypervisor capabilities.
Files: *
Copyright: © 2012 Smartjog
License: LGPL-3
See /usr/share/common-licenses/LGPL-3 for a full copy of the license.
#!/usr/bin/make -f
# -*- makefile -*-
DEB_PYTHON_SYSTEM=pycentral
# Debhelper must be included before python-distutils to use
# dh_python / dh_pycentral / dh_pysupport
include /usr/share/cdbs/1/rules/debhelper.mk
include /usr/share/cdbs/1/class/python-distutils.mk
PYTHON_PACKAGES := cc-node
$(patsubst %,binary-install/%,$(PYTHON_PACKAGES))::
dh_pycentral -p$(cdbs_curpkg)
3.0 (native)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment