diff options
| author | Mark Asselstine <mark.asselstine@windriver.com> | 2014-03-22 23:20:07 -0400 |
|---|---|---|
| committer | Bruce Ashfield <bruce.ashfield@windriver.com> | 2014-04-15 19:48:37 -0400 |
| commit | 1768e94b9e600884d43e65b3ef05e379f043a196 (patch) | |
| tree | bda7de8ecbefad7244f7b27dc0bb88354bea40be /meta-openstack/recipes-devtools/python/python-neutron_git.bb | |
| parent | 8e8d5d43698b24af551a8c2c3b766cf545a7d340 (diff) | |
| download | meta-cloud-services-1768e94b9e600884d43e65b3ef05e379f043a196.tar.gz | |
python-neutron: get the l3-agent properly packaged
The recipe had the initial groundwork established to create the
l3-agent package but some aspects were incomplete. Add the necessary
.ini file and create the initscript necessary to launch the l3-agent
at boot time.
Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com>
Diffstat (limited to 'meta-openstack/recipes-devtools/python/python-neutron_git.bb')
| -rw-r--r-- | meta-openstack/recipes-devtools/python/python-neutron_git.bb | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/meta-openstack/recipes-devtools/python/python-neutron_git.bb b/meta-openstack/recipes-devtools/python/python-neutron_git.bb index fcb8b4d..b256c79 100644 --- a/meta-openstack/recipes-devtools/python/python-neutron_git.bb +++ b/meta-openstack/recipes-devtools/python/python-neutron_git.bb | |||
| @@ -12,6 +12,7 @@ SRC_URI = "git://github.com/openstack/${SRCNAME}.git;branch=stable/havana \ | |||
| 12 | file://linuxbridge_conf.ini \ | 12 | file://linuxbridge_conf.ini \ |
| 13 | file://neutron-server.init \ | 13 | file://neutron-server.init \ |
| 14 | file://neutron-agent.init \ | 14 | file://neutron-agent.init \ |
| 15 | file://l3_agent.ini \ | ||
| 15 | " | 16 | " |
| 16 | SRCREV="8cb9d895675f2a89c6b741da4b594f416fbeee5a" | 17 | SRCREV="8cb9d895675f2a89c6b741da4b594f416fbeee5a" |
| 17 | PV="2013.2.2+git${SRCPV}" | 18 | PV="2013.2.2+git${SRCPV}" |
| @@ -53,15 +54,24 @@ do_install_append() { | |||
| 53 | install -m 600 ${S}/etc/policy.json ${NEUTRON_CONF_DIR}/ | 54 | install -m 600 ${S}/etc/policy.json ${NEUTRON_CONF_DIR}/ |
| 54 | 55 | ||
| 55 | PLUGIN=openvswitch | 56 | PLUGIN=openvswitch |
| 57 | ARGS="" | ||
| 56 | if ${@base_contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then | 58 | if ${@base_contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then |
| 57 | install -d ${D}${sysconfdir}/init.d | 59 | install -d ${D}${sysconfdir}/init.d |
| 58 | sed "s:@plugin@:/etc/neutron/plugins/$PLUGIN/ovs_neutron_plugin.ini:" \ | 60 | sed "s:@plugin@:/etc/neutron/plugins/$PLUGIN/ovs_neutron_plugin.ini:" \ |
| 59 | < ${WORKDIR}/neutron-server.init >${WORKDIR}/neutron-server.init.sh | 61 | < ${WORKDIR}/neutron-server.init >${WORKDIR}/neutron-server.init.sh |
| 60 | install -m 0755 ${WORKDIR}/neutron-server.init.sh ${D}${sysconfdir}/init.d/neutron-server | 62 | install -m 0755 ${WORKDIR}/neutron-server.init.sh ${D}${sysconfdir}/init.d/neutron-server |
| 61 | sed "s:@suffix@:$PLUGIN:" < ${WORKDIR}/neutron-agent.init >${WORKDIR}/neutron-$PLUGIN.init.sh | 63 | sed "s:@suffix@:$PLUGIN:;s:@args@:$ARGS:" < ${WORKDIR}/neutron-agent.init >${WORKDIR}/neutron-$PLUGIN.init.sh |
| 62 | install -m 0755 ${WORKDIR}/neutron-$PLUGIN.init.sh ${D}${sysconfdir}/init.d/neutron-$PLUGIN-agent | 64 | install -m 0755 ${WORKDIR}/neutron-$PLUGIN.init.sh ${D}${sysconfdir}/init.d/neutron-$PLUGIN-agent |
| 63 | fi | 65 | fi |
| 64 | 66 | ||
| 67 | AGENT=l3 | ||
| 68 | ARGS="--config-file=${sysconfdir}/${SRCNAME}/neutron.conf --config-file=${sysconfdir}/${SRCNAME}/l3_agent.ini" | ||
| 69 | if ${@base_contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then | ||
| 70 | sed "s:@suffix@:$AGENT:;s:@args@:$ARGS:" < ${WORKDIR}/neutron-agent.init >${WORKDIR}/neutron-$AGENT.init.sh | ||
| 71 | install -m 0755 ${WORKDIR}/neutron-$AGENT.init.sh ${D}${sysconfdir}/init.d/neutron-$AGENT-agent | ||
| 72 | install -m 600 ${WORKDIR}/${AGENT}_agent.ini ${NEUTRON_CONF_DIR}/ | ||
| 73 | fi | ||
| 74 | |||
| 65 | cp run_tests.sh ${NEUTRON_CONF_DIR} | 75 | cp run_tests.sh ${NEUTRON_CONF_DIR} |
| 66 | } | 76 | } |
| 67 | 77 | ||
| @@ -147,7 +157,7 @@ FILES_${SRCNAME}-dhcp-agent = "${bindir}/neutron-dhcp-agent \ | |||
| 147 | 157 | ||
| 148 | FILES_${SRCNAME}-l3-agent = "${bindir}/neutron-l3-agent \ | 158 | FILES_${SRCNAME}-l3-agent = "${bindir}/neutron-l3-agent \ |
| 149 | ${sysconfdir}/${SRCNAME}/l3_agent.ini \ | 159 | ${sysconfdir}/${SRCNAME}/l3_agent.ini \ |
| 150 | ${sysconfdir}/init.d/l3_agent \ | 160 | ${sysconfdir}/init.d/neutron-l3-agent \ |
| 151 | " | 161 | " |
| 152 | 162 | ||
| 153 | FILES_${SRCNAME}-metadata-agent = "${bindir}/neutron-metadata-agent \ | 163 | FILES_${SRCNAME}-metadata-agent = "${bindir}/neutron-metadata-agent \ |
| @@ -202,10 +212,12 @@ RDEPENDS_${SRCNAME}-setup = "postgresql sudo" | |||
| 202 | 212 | ||
| 203 | RRECOMMENDS_${SRCNAME}-server = "${SRCNAME}-plugin-openvswitch" | 213 | RRECOMMENDS_${SRCNAME}-server = "${SRCNAME}-plugin-openvswitch" |
| 204 | 214 | ||
| 205 | INITSCRIPT_PACKAGES = "${SRCNAME}-server ${SRCNAME}-plugin-openvswitch ${SRCNAME}-plugin-linuxbridge" | 215 | INITSCRIPT_PACKAGES = "${SRCNAME}-server ${SRCNAME}-plugin-openvswitch ${SRCNAME}-plugin-linuxbridge ${SRCNAME}-l3-agent" |
| 206 | INITSCRIPT_NAME_${SRCNAME}-server = "neutron-server" | 216 | INITSCRIPT_NAME_${SRCNAME}-server = "neutron-server" |
| 207 | INITSCRIPT_PARAMS_${SRCNAME}-server = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 217 | INITSCRIPT_PARAMS_${SRCNAME}-server = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 208 | INITSCRIPT_NAME_${SRCNAME}-plugin-openvswitch = "neutron-openvswitch-agent" | 218 | INITSCRIPT_NAME_${SRCNAME}-plugin-openvswitch = "neutron-openvswitch-agent" |
| 209 | INITSCRIPT_PARAMS_${SRCNAME}-plugin-openvswitch = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 219 | INITSCRIPT_PARAMS_${SRCNAME}-plugin-openvswitch = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 210 | INITSCRIPT_NAME_${SRCNAME}-plugin-linuxbridge = "neutron-linuxbridge-agent" | 220 | INITSCRIPT_NAME_${SRCNAME}-plugin-linuxbridge = "neutron-linuxbridge-agent" |
| 211 | INITSCRIPT_PARAMS_${SRCNAME}-plugin-linuxbridge = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | 221 | INITSCRIPT_PARAMS_${SRCNAME}-plugin-linuxbridge = "${OS_DEFAULT_INITSCRIPT_PARAMS}" |
| 222 | INITSCRIPT_NAME_${SRCNAME}-l3-agent = "neutron-l3-agent" | ||
| 223 | INITSCRIPT_PARAMS_${SRCNAME}-l3-agent = "${OS_DEFAULT_INITSCRIPT_PARAMS}" | ||
