This is the first in a series of commits to add support for codespell. This is continuning the process completed in ironic-python-agent.
Future Commits will add a Tox Target, CI support and potentially a git-blame-ignore-revs file if their are lots of spelling mistakes that could clutter git blame.
Change-Id: I823dfa7bd49c51f4eb7507cae67b4ef3b4e1cd6f
Since we've dropped support for Python 2.7, it's time to look at
the bright future that Python 3.x will bring and stop forcing
compatibility with older versions.
This patch removes the six library , switches the mock library
to unittest.mock and removes future.
Change-Id: I71b11f13691d13df162b203f7ea5979b30c272df
Set flake8-import-order version to 0.17.1
Full py3 compatible version.
Add all Python3 modules to stdlib list.
Also includes fix to an enum34 dependency bug.
Change-Id: I58dd80fc33942656c69ce67ee523a1d57f693e93
If Ansible hostvars contain a pipe (|) character, this can cause
problems during scheduling as Ansible fails during Jinja templating.
This is probably a bug in Ansible/Jinja.
The particular case where this was hit was when using screen, the
TERMCAP environment variable gets set to something beginning with
'SC|screen|VT'.
This change addresses the issue by moving the capture of hostvars inside
the tenks_update_state action plugin rather than evaluating them in a
playbook.
Change-Id: Ibef91d9ef499c8741b61a170672a23f530a600bb
Adds support for setting node and volume name prefixes on a per-spec
basis. This allows for different node specifications to use different
names, e.g. 'controller' vs 'compute'.
This change also fixes an issue where node names were not globally unique, only
unique on a given hypervisor. This could cause issues if used with multiple
hypervisors.
This has been done by rewriting the scheduling logic, replacing the 'node
index' concept with a more concrete reservation of IPMI ports (which are
allocated per hypervisor), and decoupling this from generation of node names
(which are allocated globally).
Change-Id: I929b18918c2886f42c4d05b37c81f3e63c69a92f
Story: 2004894
Task: 29201
Story: 31d2681
Task: 29248
node_name_prefix (default tk0) can be used to set a custom prefix for the node
names.
vol_name_prefix (default vol) can be used to set a custom prefix for the volume
names.
Support already existed for these in the action plugin, but the variables were
not passed through.
Change-Id: If968707285f9a8450bf16ca7a4956de6164986de
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
Each volume needs its own volume, so to ensure separate volumes are
created for every node, give each volume a unique name comprising the
parent node's name and the volume's index within the node's volume list.
Add a cleanup_state.yml playbook that is run after every deployment and
teardown. It will remove any nodes marked as 'absent' from the state
file, by calling schedule.py with `prune_only=True`.
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.
Instead of just an allocations file, Tenks now uses a 'state' file. This
contains the node allocations, as well as physical network mappings and
indices. Clusters can also now be re-deployed with different specs to
update the state.