Closed johnpmitsch closed 6 years ago
listing tasks works w/o yes/no prompt:
[root@sat-628-rhel7 ~]# satellite-clone --list-tasks
ansible-playbook -i /usr/share/satellite-clone/inventory --list-tasks /usr/share/satellite-clone/satellite-clone-playbook.yml
playbook: /usr/share/satellite-clone/satellite-clone-playbook.yml
play #1 (satellite6): satellite6 TAGS: []
tasks:
satellite-clone : Fail if the destination host is not rhel7 (for migration only) TAGS: []
satellite-clone : find root partition's free space TAGS: []
debug TAGS: []
satellite-clone : Check if root has enough space TAGS: []
satellite-clone : check satellite version from the config files TAGS: []
satellite-clone : setting fact - satellite_answers TAGS: []
....
Listing tasks takes precedence over any other argument:
[root@sat-628-rhel7 ~]# satellite-clone --list-tasks --start-at-task=""
ansible-playbook -i /usr/share/satellite-clone/inventory --list-tasks /usr/share/satellite-clone/satellite-clone-playbook.yml
playbook: /usr/share/satellite-clone/satellite-clone-playbook.yml
play #1 (satellite6): satellite6 TAGS: []
tasks:
satellite-clone : Fail if the destination host is not rhel7 (for migration only) TAGS: []
satellite-clone : find root partition's free space TAGS: []
debug TAGS: []
satellite-clone : Check if root has enough space TAGS: []
satellite-clone : check satellite version from the config files TAGS: []
satellite-clone : setting fact - satellite_answers TAGS: []
satellite-clone : set satellite_version to 6.2 if satellite_answers.yaml exists TAGS: []
satellite-clone : set satellite_version to 6.1 if satellite_answers.yaml does not exist TAGS: []
satellite-clone : Check for config tar file TAGS: []
....
normal flags still work
[root@sat-628-rhel7 ~]# satellite-clone --start-at-task="Test Satellite"
This will initiate satellite-clone. Do you want to proceed? (y/n): y
ansible-playbook -i /usr/share/satellite-clone/inventory --start-at-task Test Satellite /usr/share/satellite-clone/satellite-clone-playbook.yml
PLAY [satellite6] ****************************************************************************************************************************************************************************
TASK [Gathering Facts] ***********************************************************************************************************************************************************************
Fixes #265