For standalone ironic deployments, such as those deployed using bifrost, there
is typically no keystone or placement service running. Use of the ironic API is
without authentication. We use clouds.yaml in this case.
Change-Id: I61ed791d019e43f6dfc632fa185f079b385c290c
Story: 2004425
Task: 28077
In the Ocata release, the physical_network field of ports did not exist.
The safest thing to do is to simply ignore it in this case.
It is also possible for the local_link_connection fields to not have switch_id,
switch_info or port_id attributes, so we now use .get(attr) to avoid an
attribute lookup error.
Change-Id: Ib4829dbd89fcedc121f493d6af76702421b399f7
TrivialFix
Ansible lint has become more fussy about its nit picking, blocking CI.
This change makes it happy again.
Change-Id: Ifb86c5e071697acda014bb543cab7ebf2b648dc9
Somewhere along the line, the default None value for deploy_kernel and
deploy_ramdisk gets converted to a string. Allow for both possibilities.
Change-Id: Ia06bff344262f82956da1d6548bae9a30fcdffd9
TrivialFix
If the ironic_config field is not present in a node definition, then
that node should not be registered with ironic. In this case we also
don't need to query glance for images or wait for resources to appear
in placement.
If nova_flavors is empty, we do not need to register flavors, so no need
to install the client or check for OS_USERNAME.
Also fixes an issue in the action plugin where it would fail if
ironic_config field is not present in a node definition.
Finally, in CI deploy/teardown tests, rather than skipping tasks, we now
remove the ironic_config field from the node definition, and set
nova_flavors to empty, such that we exercise these code paths.
Change-Id: I29b42665f1609c99e80f12ab6f3815d0e0918dae
Story: 2004412
Task: 28056
This, for example, allows you to run libvirt with non-default
socket path.
Change-Id: Ia01f39f425cccc6acebd31f77b46b1948e24d215
Story: 2004344
Task: 27935
This will wait for any resources that are created to become available
before exiting the script. This allows you to avoid a race condition
where a server could be created before the resource tracker had been
updated with the new resources; server creation would fail.
Change-Id: I57f8c93cb1ebbc284b96ef1ced2c4edd59b27795
Story: 2004274
Task: 27823
Depends-On: https://review.openstack.org/617642
bridge-utils is considered legacy and many distributions do
not ship it as default.
Change-Id: Id2f9d779d12a5135d7d7e7a4783c6f3a0c8647ca
Story: 2004302
Task: 27861
This fixes a lint issue:
[301] Commands should not change things if nothing needs doing
/home/will/code/tenks/ansible/roles/ironic-enrolment/tasks/port.yml:20
Task/Handler: Set Ironic port attributes
TrivialFix
Change-Id: I7940fe25d3518daf268484e292e337abc925080d
On RedHat based distros /bin/ is a symlink to /usr/bin:
[will@dev-director ~]$ ls -lia /bin
410146 lrwxrwxrwx. 1 root root 7 Jun 11 12:07 /bin -> usr/bin
Whereas on the Ubuntu it is seperate directory. Using
/usr/bin/virsh should work on both.
ubuntu:
stack@ubuntu:~/ansible-role-libvirt-vm$ whereis virsh
virsh: /usr/bin/virsh /usr/share/man/man1/virsh.1
centos:
[will@dev-director ~]$ whereis virsh
virsh: /usr/bin/virsh /usr/share/man/man1/virsh.1.gz
Also removed a misleading comment. QEMU uses differnt
"instances" for privaleged and user access i.e the
"system" and "session" instances. The comment seemed
to suggest using /bin/virsh would connect to the
system instance (at least that is how I read it).
The OpenStack client Python package is not necessarily installed in the
Tenks virtualenv until the role is run, so we need to query OpenStack
for the image IDs inside the role.
You can now use either a name or a UUID for these images. Also, remove
the unnecessary setting of node states, which is now handled by the
scheduling plugin.
Instead of overwriting the physnet mappings specified in the Tenks
configuration, create a separate dict that maps physnet names to their
indices. Like physnet_mappings, this will be present for each
hypervisor.
* Don't delete the OVS bridge specified, as it will already be deleted
when the role is called.
* Clarify the behaviour of the role for each value of `cmd` in the
README.
* Succintify main.yml.
Pass any interface that was specified through to Ironic; otherwise, let
Ironic decide a default for it. Also, pass through any property
key-value pairs we get.
Create a role to configure a host for Virtual BMC, and another to add
domains to it.
Also add some checking to make the roles more robust.
Conflicts:
ansible/deploy.yml
ansible/libvirt_create_vms.yml
ansible/roles/virtualbmc/tasks/main.yml