FreeKB - import_playbook module
Ansible - import_playbook module

This assumes you have installed Ansible, are familiar with the ansible-playbook command and have created a playbook.

import_playbook can be used to import one playbook into another playbook. A command uses of this is to have a master parent playbook that performs plays from child playbooks, like this.

- import_playbook: child.yml

 

Or like this.

- name: first child playbook
  import_playbook: child.yml

 

import_playbook cannot be run inside a task. For example, this would not work. include_tasks can be used to run a playbook within tasks.

- hosts: all
  tasks:
    import_playbook: child.yml

 



Add a Comment




We will never share your name or email with anyone. Enter your email if you would like to be notified when we respond to your comment.




Please enter 45e0f in the box below so that we can be sure you are a human.




Comments