mirror of https://github.com/ceph/ceph-ansible.git
tests: various fixes in tox.ini
- the collection path isn't right - vagrant_up.sh fails because the path isn't passed down - increase the number of retries and delay for pytest Signed-off-by: Guillaume Abrioux <gabrioux@ibm.com>pull/7558/head
parent
2b711f7601
commit
a20c6919cf
|
@ -12,7 +12,7 @@ allowlist_externals =
|
|||
passenv=*
|
||||
setenv=
|
||||
ANSIBLE_SSH_ARGS = -F {changedir}/vagrant_ssh_config -o ControlMaster=auto -o ControlPersist=600s -o PreferredAuthentications=publickey
|
||||
ANSIBLE_COLLECTIONS_PATH = {envdir}
|
||||
ANSIBLE_COLLECTIONS_PATH = {envdir}/ansible_collections
|
||||
ANSIBLE_CONFIG = {toxinidir}/ansible.cfg
|
||||
ANSIBLE_CALLBACK_ENABLED = profile_tasks
|
||||
ANSIBLE_CACHE_PLUGIN = memory
|
||||
|
@ -32,7 +32,7 @@ deps= -r{toxinidir}/tests/requirements.txt
|
|||
changedir={toxinidir}/tests/functional/external_clients{env:CONTAINER_DIR:}
|
||||
commands=
|
||||
ansible-galaxy collection install -r {toxinidir}/requirements.yml -v -p {envdir}/ansible_collections
|
||||
bash {toxinidir}/tests/scripts/vagrant_up.sh --no-provision {posargs:--provider=virtualbox}
|
||||
bash {toxinidir}/tests/scripts/vagrant_up.sh {changedir} --no-provision {posargs:--provider=virtualbox}
|
||||
bash {toxinidir}/tests/scripts/generate_ssh_config.sh {changedir}
|
||||
|
||||
ansible-playbook -vv -i {changedir}/inventory {toxinidir}/tests/functional/setup.yml
|
||||
|
|
|
@ -39,7 +39,7 @@ deps= -r{toxinidir}/tests/requirements.txt
|
|||
changedir={toxinidir}/tests/functional/rbdmirror{env:CONTAINER_DIR:}
|
||||
commands=
|
||||
ansible-galaxy install -r {toxinidir}/requirements.yml -v
|
||||
bash {toxinidir}/tests/scripts/vagrant_up.sh --no-provision {posargs:--provider=virtualbox}
|
||||
bash {toxinidir}/tests/scripts/vagrant_up.sh {changedir} --no-provision {posargs:--provider=virtualbox}
|
||||
bash {toxinidir}/tests/scripts/generate_ssh_config.sh {changedir}
|
||||
|
||||
ansible-playbook -vv -i {changedir}/{env:INVENTORY} {toxinidir}/tests/functional/setup.yml
|
||||
|
@ -58,7 +58,7 @@ commands=
|
|||
ceph_docker_registry_password={env:DOCKER_HUB_PASSWORD} \
|
||||
"
|
||||
|
||||
bash -c "cd {changedir}/secondary && bash {toxinidir}/tests/scripts/vagrant_up.sh --no-provision {posargs:--provider=virtualbox}"
|
||||
bash -c "cd {changedir}/secondary && bash {toxinidir}/tests/scripts/vagrant_up.sh {changedir}/secondary --no-provision {posargs:--provider=virtualbox}"
|
||||
bash -c "cd {changedir}/secondary && bash {toxinidir}/tests/scripts/generate_ssh_config.sh {changedir}/secondary"
|
||||
ansible-playbook --ssh-common-args='-F {changedir}/secondary/vagrant_ssh_config -o ControlMaster=auto -o ControlPersist=600s -o PreferredAuthentications=publickey' -vv -i {changedir}/secondary/hosts {toxinidir}/tests/functional/setup.yml
|
||||
ansible-playbook --ssh-common-args='-F {changedir}/secondary/vagrant_ssh_config -o ControlMaster=auto -o ControlPersist=600s -o PreferredAuthentications=publickey' -vv -i {changedir}/secondary/hosts {toxinidir}/tests/functional/lvm_setup.yml
|
||||
|
|
|
@ -35,7 +35,7 @@ deps= -r{toxinidir}/tests/requirements.txt
|
|||
changedir={toxinidir}/tests/functional/subset_update{env:CONTAINER_DIR:}
|
||||
commands=
|
||||
ansible-galaxy collection install -r {toxinidir}/requirements.yml -v -p {envdir}/ansible_collections
|
||||
bash {toxinidir}/tests/scripts/vagrant_up.sh --no-provision {posargs:--provider=virtualbox}
|
||||
bash {toxinidir}/tests/scripts/vagrant_up.sh {changedir} --no-provision {posargs:--provider=virtualbox}
|
||||
bash {toxinidir}/tests/scripts/generate_ssh_config.sh {changedir}
|
||||
|
||||
ansible-playbook -vv -i {changedir}/{env:INVENTORY} {toxinidir}/tests/functional/setup.yml
|
||||
|
|
|
@ -34,7 +34,7 @@ setenv=
|
|||
ROLLING_UPDATE = True
|
||||
changedir={toxinidir}/tests/functional/all_daemons{env:CONTAINER_DIR:}
|
||||
commands=
|
||||
bash {toxinidir}/tests/scripts/vagrant_up.sh --no-provision {posargs:--provider=virtualbox}
|
||||
bash {toxinidir}/tests/scripts/vagrant_up.sh {changedir} --no-provision {posargs:--provider=virtualbox}
|
||||
bash {toxinidir}/tests/scripts/generate_ssh_config.sh {changedir}
|
||||
|
||||
# use the stable-6.0 branch to deploy a pacific cluster
|
||||
|
@ -83,6 +83,6 @@ commands=
|
|||
ceph_docker_registry_password={env:DOCKER_HUB_PASSWORD} \
|
||||
"
|
||||
|
||||
bash -c "CEPH_STABLE_RELEASE=quincy py.test --reruns 5 --reruns-delay 1 -n 8 --durations=0 --sudo -v --connection=ansible --ansible-inventory={changedir}/{env:INVENTORY} --ssh-config={changedir}/vagrant_ssh_config {toxinidir}/tests/functional/tests"
|
||||
bash -c "CEPH_STABLE_RELEASE=quincy py.test --reruns 30 --reruns-delay 2 -n 8 --durations=0 --sudo -v --connection=ansible --ansible-inventory={changedir}/{env:INVENTORY} --ssh-config={changedir}/vagrant_ssh_config {toxinidir}/tests/functional/tests"
|
||||
|
||||
vagrant destroy --force
|
||||
|
|
6
tox.ini
6
tox.ini
|
@ -160,7 +160,7 @@ commands=
|
|||
|
||||
ansible-playbook -vv -i {changedir}/{env:INVENTORY} {toxinidir}/tests/functional/reboot.yml
|
||||
|
||||
py.test --reruns 5 --reruns-delay 1 -n 8 --durations=0 --sudo -v --connection=ansible --ansible-inventory={changedir}/hosts-switch-to-containers --ssh-config={changedir}/vagrant_ssh_config {toxinidir}/tests/functional/tests
|
||||
py.test --reruns 30 --reruns-delay 2 -n 8 --durations=0 --sudo -v --connection=ansible --ansible-inventory={changedir}/hosts-switch-to-containers --ssh-config={changedir}/vagrant_ssh_config {toxinidir}/tests/functional/tests
|
||||
|
||||
[add-mons]
|
||||
commands=
|
||||
|
@ -274,7 +274,7 @@ setenv=
|
|||
ANSIBLE_KEEP_REMOTE_FILES = 1
|
||||
ANSIBLE_CACHE_PLUGIN = memory
|
||||
ANSIBLE_GATHERING = implicit
|
||||
ANSIBLE_COLLECTIONS_PATH = {envdir}
|
||||
ANSIBLE_COLLECTIONS_PATH = {envdir}/ansible_collections
|
||||
# only available for ansible >= 2.5
|
||||
ANSIBLE_STDOUT_CALLBACK = yaml
|
||||
non_container: DEV_SETUP = True
|
||||
|
@ -331,7 +331,7 @@ commands=
|
|||
ansible-galaxy collection install -r {toxinidir}/requirements.yml -v -p {envdir}/ansible_collections
|
||||
rhcs: ansible-playbook -vv -i "localhost," -c local {toxinidir}/tests/functional/rhcs_setup.yml --extra-vars "change_dir={changedir}" --tags "vagrant_setup"
|
||||
|
||||
bash {toxinidir}/tests/scripts/vagrant_up.sh --no-provision {posargs:--provider=virtualbox}
|
||||
bash {toxinidir}/tests/scripts/vagrant_up.sh {changedir} --no-provision {posargs:--provider=virtualbox}
|
||||
bash {toxinidir}/tests/scripts/generate_ssh_config.sh {changedir}
|
||||
|
||||
# configure lvm, we exclude osd2 given this node uses lvm batch scenario (see corresponding inventory host file)
|
||||
|
|
Loading…
Reference in New Issue