make dnsmasq compile optional
Some users wont want to compile source, and instead choose to build or otherwise install a package for dnsmasq on precise This does not change the default behavior, just provides a short circuit mechanism for folks who don't want to have these recipes build from source Change-Id: I85ee904f2bc47dc352b13e2c6f35e14e2084b5d2
This commit is contained in:
parent
6bb1deb05b
commit
3e47f2a6d3
|
@ -2,6 +2,9 @@
|
|||
|
||||
This file is used to list changes made in each version of cookbook-openstack-network.
|
||||
|
||||
## 8.1.1
|
||||
* allow dnsmasq source build to be optional
|
||||
|
||||
## 8.1.0
|
||||
* Add client recipe
|
||||
|
||||
|
|
|
@ -198,6 +198,9 @@ default['openstack']['network']['dhcp']['enable_metadata_network'] = 'False'
|
|||
# See https://lists.launchpad.net/openstack/msg11696.html
|
||||
default['openstack']['network']['dhcp']['dnsmasq_url'] = 'https://github.com/guns/dnsmasq/archive/v2.65.tar.gz'
|
||||
|
||||
# allow a wrapper to do this another way or use it's own package
|
||||
default['openstack']['network']['dhcp']['dnsmasq_compile'] = true
|
||||
|
||||
# The name of the file we will fetch
|
||||
default['openstack']['network']['dhcp']['dnsmasq_filename'] = 'v2.65.tar.gz'
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@ maintainer 'Jay Pipes <jaypipes@gmail.com>'
|
|||
license 'Apache 2.0'
|
||||
description 'Installs and configures the OpenStack Network API Service and various agents and plugins'
|
||||
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
|
||||
version '8.1.0'
|
||||
version '8.1.1'
|
||||
recipe 'openstack-network::client', 'Install packages required for network client'
|
||||
recipe 'openstack-network::server', 'Installs packages required for a OpenStack Network server'
|
||||
recipe 'openstack-network::openvswitch', 'Installs packages required for OVS'
|
||||
|
|
|
@ -76,8 +76,7 @@ end
|
|||
#
|
||||
# Would prefer a PPA or backport but there are none and upstream
|
||||
# has no plans to fix
|
||||
if node['lsb'] && node['lsb']['codename'] == 'precise'
|
||||
|
||||
if node['lsb'] && node['lsb']['codename'] == 'precise' && node['openstack']['network']['dhcp']['dnsmasq_compile'] == true
|
||||
platform_options['neutron_dhcp_build_packages'].each do |pkg|
|
||||
package pkg do
|
||||
action :install
|
||||
|
|
|
@ -29,6 +29,17 @@ describe 'openstack-network::dhcp_agent' do
|
|||
end
|
||||
end
|
||||
|
||||
it 'skips dnsmasq build when asked to' do
|
||||
@chef_run = ::ChefSpec::Runner.new ::UBUNTU_OPTS
|
||||
node = @chef_run.node
|
||||
node.set['openstack']['compute']['network']['service_type'] = 'quantum'
|
||||
node.set['openstack']['network']['dhcp']['dnsmasq_compile'] = false
|
||||
@chef_run.converge 'openstack-network::dhcp_agent'
|
||||
%w(build-essential pkg-config libidn11-dev libdbus-1-dev libnetfilter-conntrack-dev gettext).each do |pkg|
|
||||
expect(@chef_run).to_not install_package pkg
|
||||
end
|
||||
end
|
||||
|
||||
it 'installs quamtum dhcp package' do
|
||||
expect(@chef_run).to install_package 'neutron-dhcp-agent'
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue