Add configs to pass user_data_file

1. Add configs to pass user_data_file;
2. Update dependencies to fix sphinx error;

Change-Id: I1b9c1576f4e59e3026e527502a90b3db4b95fb3b
This commit is contained in:
Yichen Wang 2016-04-20 15:41:18 -07:00
parent fac83b68e8
commit 3e3be62ba4
4 changed files with 12 additions and 3 deletions

View File

@ -3,5 +3,6 @@ flake8>=2.3.0
git-review>=1.24
pylint>=1.3
pep8>=1.5.7
sphinx>=1.2.3
sphinx>=1.4.0
sphinx_rtd_theme>=0.1.9
tox>=1.9.0

View File

@ -7,7 +7,8 @@ hacking<0.11,>=0.10.0
coverage>=3.6
discover
python-subunit>=0.0.18
sphinx>=1.3.1
sphinx>=1.4.0
sphinx_rtd_theme>=0.1.9
oslosphinx>=2.5.0 # Apache-2.0
oslotest>=1.10.0 # Apache-2.0
testrepository>=0.0.18

View File

@ -74,6 +74,10 @@ reuse_existing_vm:
# An option of config_drive to True is provided to nova boot to enable this
config_drive:
# The location of the user_data file, which will be passed to every instance
# when booting.
user_data_file:
# ipv6 mode. Set this to one of the following 3 modes
# slaac : VM obtains IPV6 address from Openstack radvd using SLAAC
# dhcpv6-stateful : VM obtains ipv6 address from dnsmasq using DHCPv6 stateful

View File

@ -153,13 +153,16 @@ class VmtpTest(object):
# Create an instance on a particular availability zone
def create_instance(self, inst, az, int_net):
fn = self.config.user_data_file
user_data_file = fn if fn and os.path.isfile(fn) else None
self.assert_true(inst.create(self.image_instance,
self.flavor_type,
self.instance_access,
int_net,
az,
int_net['name'],
self.sec_group))
self.sec_group,
init_file_name=user_data_file))
def assert_true(self, cond):
if not cond: