Don't specify inventory in base molecule config file

The host list gets merged by molecule, causing an unwanted "instance"
host in the inventory. Let's keep the inventory definition inside role
configs.

Closes-Bug: 1964595
Change-Id: Ida4b9e08c6cff6d140451df75b1807b89e6de073
This commit is contained in:
Rafael Castillo 2022-03-11 11:05:34 -07:00
parent 3b86a609a7
commit 77b56d10f1
14 changed files with 91 additions and 6 deletions

View File

@ -27,12 +27,6 @@ provisioner:
defaults:
fact_caching: jsonfile
fact_caching_connection: /tmp/molecule/facts
inventory:
hosts:
all:
hosts:
instance:
ansible_host: localhost
log: true
env:
ANSIBLE_STDOUT_CALLBACK: yaml

View File

@ -1,6 +1,13 @@
---
# inherits .config/molecule/config.yml
provisioner:
inventory:
hosts:
all:
hosts:
instance:
ansible_connection: local
ansible_host: localhost
playbooks:
prepare: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/prepare.yml"
cleanup: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/cleanup.yml"

View File

@ -1,6 +1,13 @@
---
# inherits .config/molecule/config.yml
provisioner:
inventory:
hosts:
all:
hosts:
instance:
ansible_connection: local
ansible_host: localhost
playbooks:
prepare: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/prepare.yml"
cleanup: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/cleanup.yml"

View File

@ -1,6 +1,13 @@
---
# inherits .config/molecule/config.yml
provisioner:
inventory:
hosts:
all:
hosts:
instance:
ansible_connection: local
ansible_host: localhost
playbooks:
prepare: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/prepare.yml"
cleanup: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/cleanup.yml"

View File

@ -1,6 +1,13 @@
---
# inherits .config/molecule/config.yml
provisioner:
inventory:
hosts:
all:
hosts:
instance:
ansible_connection: local
ansible_host: localhost
playbooks:
prepare: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/prepare.yml"
cleanup: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/cleanup.yml"

View File

@ -1,6 +1,13 @@
---
# inherits .config/molecule/config.yml
provisioner:
inventory:
hosts:
all:
hosts:
instance:
ansible_connection: local
ansible_host: localhost
playbooks:
prepare: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/prepare.yml"
cleanup: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/cleanup.yml"

View File

@ -1,6 +1,13 @@
---
# inherits .config/molecule/config.yml
provisioner:
inventory:
hosts:
all:
hosts:
instance:
ansible_connection: local
ansible_host: localhost
playbooks:
prepare: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/prepare.yml"
cleanup: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/cleanup.yml"

View File

@ -1,6 +1,13 @@
---
# inherits .config/molecule/config.yml
provisioner:
inventory:
hosts:
all:
hosts:
instance:
ansible_connection: local
ansible_host: localhost
playbooks:
prepare: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/prepare.yml"
cleanup: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/cleanup.yml"

View File

@ -1,6 +1,13 @@
---
# inherits .config/molecule/config.yml
provisioner:
inventory:
hosts:
all:
hosts:
instance:
ansible_connection: local
ansible_host: localhost
playbooks:
prepare: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/prepare.yml"
cleanup: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/cleanup.yml"

View File

@ -1,6 +1,13 @@
---
# inherits .config/molecule/config.yml
provisioner:
inventory:
hosts:
all:
hosts:
instance:
ansible_connection: local
ansible_host: localhost
playbooks:
prepare: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/prepare.yml"
cleanup: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/cleanup.yml"

View File

@ -1,6 +1,13 @@
---
# inherits .config/molecule/config.yml
provisioner:
inventory:
hosts:
all:
hosts:
instance:
ansible_connection: local
ansible_host: localhost
playbooks:
prepare: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/prepare.yml"
cleanup: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/cleanup.yml"

View File

@ -1,6 +1,13 @@
---
# inherits .config/molecule/config.yml
provisioner:
inventory:
hosts:
all:
hosts:
instance:
ansible_connection: local
ansible_host: localhost
playbooks:
prepare: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/prepare.yml"
cleanup: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/cleanup.yml"

View File

@ -1,6 +1,13 @@
---
# inherits .config/molecule/config.yml
provisioner:
inventory:
hosts:
all:
hosts:
instance:
ansible_connection: local
ansible_host: localhost
playbooks:
prepare: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/prepare.yml"
cleanup: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/cleanup.yml"

View File

@ -1,6 +1,13 @@
---
# inherits .config/molecule/config.yml
provisioner:
inventory:
hosts:
all:
hosts:
instance:
ansible_connection: local
ansible_host: localhost
playbooks:
prepare: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/prepare.yml"
cleanup: "${MOLECULE_SCENARIO_DIRECTORY}/../../resources/molecule/cleanup.yml"