Commit 8de59fd3 authored by Thibault VINCENT's avatar Thibault VINCENT
Browse files

add version tag of cc-node to hv and move version information to module __init__

parent 9f929364
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -19,7 +19,7 @@ try:
except ImportError:
    DAEMONIZE = False

__VERSION__ = 6
from ccnode import __version__

DEFAULT_CONFIG_FILE = '/etc/cc-node.conf'
DEFAULT_PID_FILE = '/var/run/cc-node.pid'
@@ -107,7 +107,7 @@ def run_node(options):
if __name__ == '__main__':

    usage = 'usage: %prog [OPTION...]'
    op = OptionParser(usage, version='%%prog %s' % __VERSION__)
    op = OptionParser(usage, version='%%prog %s' % __version__)
    op.add_option('-c', '--config', default=DEFAULT_CONFIG_FILE,
                  help='configuration file (default: %default)')
    op.add_option('-d', '--daemonize', default=False, action='store_true',
+4 −2
Original line number Diff line number Diff line
@@ -66,5 +66,7 @@ each class.
from kvm import *
import ccnodehandlers

__version__ = 6

__all__ = ['kvm', 'interface', 'exceptions', 'libvirtwrapper',
           'ccnode', 'ccnodehandlers']
+3 −0
Original line number Diff line number Diff line
@@ -2,6 +2,7 @@
#TODO: catch livbirt disconnection errors and handle it 


from __init__ import __version__
from interface import Host
from kvm import *
from sjrpc.utils import RpcHandler
@@ -156,6 +157,8 @@ class NodeHandler(RpcHandler):
        result = {}
        if tags is None:
            tags = HV_TAG_WRAP_MAP.keys()
        # static tags
        result['version'] = str(__version__)
        # direct wrapping
        for tag in tags:
            try:
+2 −1
Original line number Diff line number Diff line
@@ -49,7 +49,8 @@ copyright = u'2010, Smartjog'
# built documents.
#
# The short X.Y version.
version = 3
from ccnode import __version__
version = __version__
# The full version, including alpha/beta/rc tags.
release = version

+3 −1
Original line number Diff line number Diff line
@@ -3,9 +3,11 @@ import os

ldesc = open(os.path.join(os.path.dirname(__file__), 'README')).read()

from ccnode import __version__

setup(
    name='cc-node',
    version='6',
    version=__version__,
    description='Cloud Control Node',
    long_description=ldesc,
    author='Thibault VINCENT',