eklavya / activeGrid

activeGrid in Scala
Apache License 2.0
2 stars 7 forks source link

Implementation of AnsiblePlayBookRunner execution part. #104

Open sivakumargollu opened 7 years ago

sivakumargollu commented 7 years ago

Playbook in ansible represents configuration, deployment, and orchestrator in a YML file. Each ansible playbook map hosts to roles. Each role consists of multiple calls to Ansible.

Keywords: Inventory(hostfile+group directory), the Ansible, pulls host specific group variables using from group directory under ansible home direcotry. The Implementation contains following steps.

Steps:

  1. Create a file with workflow-id as its name under the directory configures in workflowconstans.TMP_LOC
  2. Using ProcessBuilder create a process to run playbook. ProcessBuilder wraps a sequence of commands into a single unit and execute them.
  3. Write output to a logfile.
  4. Exit process safely.