summaryrefslogtreecommitdiffstats
path: root/meta-openstack/recipes-devtools/python
diff options
context:
space:
mode:
authorMihai Prica <prica.mihai@gmail.com>2013-05-17 17:41:58 +0300
committerBruce Ashfield <bruce.ashfield@windriver.com>2013-08-28 18:41:55 -0400
commitc3302d1371bfc97e88f952d94589ae79ab61eaf8 (patch)
treeea93e588b72fb05a542e218aa743ffbe9b0b0be5 /meta-openstack/recipes-devtools/python
parentc05a223f2074e9b6899295da32e1edb7d19cbdf8 (diff)
downloadmeta-cloud-services-c3302d1371bfc97e88f952d94589ae79ab61eaf8.tar.gz
python-nova: added 2013.1
The configuration files are populated with default options. Signed-off-by: Mihai Prica <prica.mihai@gmail.com>
Diffstat (limited to 'meta-openstack/recipes-devtools/python')
-rw-r--r--meta-openstack/recipes-devtools/python/python-nova/nova.conf48
-rw-r--r--meta-openstack/recipes-devtools/python/python-nova_2013.1.bb122
2 files changed, 170 insertions, 0 deletions
diff --git a/meta-openstack/recipes-devtools/python/python-nova/nova.conf b/meta-openstack/recipes-devtools/python/python-nova/nova.conf
new file mode 100644
index 0000000..a1632a0
--- /dev/null
+++ b/meta-openstack/recipes-devtools/python/python-nova/nova.conf
@@ -0,0 +1,48 @@
1[DEFAULT]
2firewall_driver = nova.virt.libvirt.firewall.IptablesFirewallDriver
3compute_driver = libvirt.LibvirtDriver
4libvirt_type = kvm
5libvirt_cpu_mode = none
6default_floating_pool = public
7fixed_range =
8force_dhcp_release = True
9dhcpbridge_flagfile = /etc/nova/nova.conf
10dhcpbridge_flagfile = /etc/nova/nova.conf
11compute_scheduler_driver = nova.scheduler.filter_scheduler.FilterScheduler
12rootwrap_config = /etc/nova/rootwrap.conf
13api_paste_config = /etc/nova/api-paste.ini
14allow_resize_to_same_host = true
15auth_strategy = keystone
16instances_path = /etc/nova/instances
17debug = True
18verbose = True
19my_ip = 127.0.0.1
20
21#VNC
22vnc_enabled = true
23vncserver_listen = 0.0.0.0
24
25#Network
26flat_interface = eth0
27flat_network_bridge = br1
28vlan_interface = eth0
29public_interface = br1
30network_manager = nova.network.manager.FlatDHCPManager
31fixed_range=
32force_dhcp_release=False
33dhcpbridge=/usr/bin/nova-dhcpbridge
34
35#Database configuration
36#Sample MySQL configuration
37#sql_connection = mysql://root:@localhost/nova?charset=utf8
38
39#Sample Sqlite configuration
40sql_connection = sqlite:////etc/nova/nova.db
41
42#Messaging system
43#fake_rabbit=true
44#Sample Qpid configuration
45rpc_backend=nova.rpc.impl_qpid
46qpid_hostname=localhost
47qpid_broker=5672
48
diff --git a/meta-openstack/recipes-devtools/python/python-nova_2013.1.bb b/meta-openstack/recipes-devtools/python/python-nova_2013.1.bb
new file mode 100644
index 0000000..94a342f
--- /dev/null
+++ b/meta-openstack/recipes-devtools/python/python-nova_2013.1.bb
@@ -0,0 +1,122 @@
1DESCRIPTION = "Nova is a cloud computing fabric controller"
2HOMEPAGE = "https://launchpad.net/nova"
3SECTION = "devel/python"
4LICENSE = "Apache-2.0"
5LIC_FILES_CHKSUM = "file://LICENSE;md5=1dece7821bf3fd70fe1309eaa37d52a2"
6
7DEPENDS = "sudo"
8
9PR = "r0"
10SRCNAME = "nova"
11
12SRC_URI = "https://launchpad.net/${SRCNAME}/grizzly/${PV}/+download/${SRCNAME}-${PV}.tar.gz \
13 file://nova.conf"
14
15
16SRC_URI[md5sum] = "38022353c398ce38c4e220d1d18b5916"
17SRC_URI[sha256sum] = "db7f5259d848358bf14105d5833869ec145f643312e6bc0adef0050120fe3e07"
18
19S = "${WORKDIR}/${SRCNAME}-${PV}"
20
21inherit setuptools useradd
22
23do_install_append() {
24
25 NOVA_CONF_DIR=${D}/${sysconfdir}/nova
26
27 install -d ${NOVA_CONF_DIR}
28 install -m 600 ${S}/etc/nova/policy.json ${NOVA_CONF_DIR}/
29
30 # Deploy filters to /etc/nova/rootwrap.d
31 install -m 755 -d ${NOVA_CONF_DIR}/rootwrap.d
32 install -m 600 ${S}/etc/nova/rootwrap.d/*.filters ${NOVA_CONF_DIR}/rootwrap.d
33 chown -R root:root ${NOVA_CONF_DIR}/rootwrap.d
34 chmod 644 ${NOVA_CONF_DIR}/rootwrap.d
35
36 # Set up rootwrap.conf, pointing to /etc/nova/rootwrap.d
37 install -m 644 ${S}/etc/nova/rootwrap.conf ${NOVA_CONF_DIR}/
38 sed -e "s:^filters_path=.*$:filters_path=${NOVA_CONF_DIR}/rootwrap.d:" -i ${NOVA_CONF_DIR}/rootwrap.conf
39 chown root:root $NOVA_CONF_DIR/rootwrap.conf
40
41 # Set up the rootwrap sudoers for nova
42 install -d ${D}${sysconfdir}/sudoers.d
43 touch ${D}${sysconfdir}/sudoers.d/nova-rootwrap
44 chmod 0440 ${D}${sysconfdir}/sudoers.d/nova-rootwrap
45 chown root:root ${D}${sysconfdir}/sudoers.d/nova-rootwrap
46 echo "root ALL=(root) NOPASSWD: nova-rootwrap" > ${D}${sysconfdir}/sudoers.d/nova-rootwrap
47
48 # Get the sample configuration file in place
49 install -m 664 ${S}/etc/nova/api-paste.ini ${NOVA_CONF_DIR}
50
51 #Copy the configuration file
52 install -m 664 ${WORKDIR}/nova.conf ${NOVA_CONF_DIR}/nova.conf
53
54 # Create the sqlite database
55 touch ${NOVA_CONF_DIR}/nova.db
56 install -d ${NOVA_CONF_DIR}/instances
57}
58
59inherit useradd
60
61USERADD_PACKAGES = "${PN}"
62GROUPADD_PARAM_${PN} = "--system nova"
63USERADD_PARAM_${PN} = "--system --home /var/lib/nova -g nova \
64 --no-create-home --shell /bin/false nova"
65
66pkg_postinst_${PN} () {
67 if [ "x$D" != "x" ]; then
68 exit 1
69 fi
70
71 # Needed when using a MySQL backend
72 # mysql -u root -e "CREATE DATABASE nova CHARACTER SET latin1;"
73 nova-manage db sync
74}
75
76PACKAGECONFIG ??= "sqlite"
77
78PACKAGECONFIG[sqlite] = ",,,sqlite3"
79PACKAGECONFIG[mysql] = ",,,mysql5-server mysql5-client mysql-python libmysqlclient"
80
81FILES_${PN} += "${sysconfdir}/${SRCNAME}/* \
82 ${sysconfdir}/sudoers.d "
83
84RDEPENDS_${PN} = "openssl openssl-misc libxml2 libxslt iptables curl dnsmasq sudo procps\
85 qemu libvirt libvirt-libvirtd libvirt-python libvirt-virsh \
86 python-modules \
87 python-misc \
88 python-argparse \
89 libvirt-python \
90 libvirt-libvirtd \
91 python-amqplib \
92 python-anyjson \
93 python-babel \
94 python-boto \
95 python-cinderclient \
96 python-cheetah \
97 python-eventlet \
98 python-feedparser \
99 python-glanceclient \
100 python-greenlet \
101 python-httplib2 \
102 python-iso8601 \
103 python-kombu \
104 python-lxml \
105 python-netaddr \
106 python-oslo.config \
107 python-paste \
108 python-pastedeploy \
109 python-paramiko \
110 python-pyasn1 \
111 python-setuptools-git \
112 python-simplejson \
113 python-setuptools \
114 python-sqlalchemy \
115 python-sqlalchemy-migrate \
116 python-stevedore \
117 python-suds \
118 python-quantumclient \
119 python-routes \
120 python-webob \
121 python-websockify \
122 "