2020-10-29 01:54:57 +07:00
|
|
|
# ansible-pull
|
|
|
|
|
|
|
|
> Pull ansible playbooks from a VCS repo and executes them for the local host.
|
|
|
|
> More information: <https://docs.ansible.com/ansible/latest/cli/ansible-pull.html>.
|
|
|
|
|
|
|
|
- Pull a playbook from a VCS and execute a default local.yml playbook:
|
|
|
|
|
2025-04-22 15:48:30 +03:00
|
|
|
`ansible-pull {{[-U|--url]}} {{repository_url}}`
|
2020-10-29 01:54:57 +07:00
|
|
|
|
|
|
|
- Pull a playbook from a VCS and execute a specific playbook:
|
|
|
|
|
2025-04-22 15:48:30 +03:00
|
|
|
`ansible-pull {{[-U|--url]}} {{repository_url}} {{playbook}}`
|
2020-10-29 01:54:57 +07:00
|
|
|
|
|
|
|
- Pull a playbook from a VCS at a specific branch and execute a specific playbook:
|
|
|
|
|
2025-04-22 15:48:30 +03:00
|
|
|
`ansible-pull {{[-U|--url]}} {{repository_url}} {{[-C|--checkout]}} {{branch}} {{playbook}}`
|
2020-10-29 01:54:57 +07:00
|
|
|
|
|
|
|
- Pull a playbook from a VCS, specify hosts file and execute a specific playbook:
|
|
|
|
|
2025-04-22 15:48:30 +03:00
|
|
|
`ansible-pull {{[-U|--url]}} {{repository_url}} {{[-i|--inventory-file]}} {{hosts_file}} {{playbook}}`
|