Ansible Azure create VM with Java installed

Hi,

I am new to Ansible. I have two separate playbooks to create VM and Install Java on it.
I am trying to create a single playbook which creates an VM with latest Java installed on it. Please help.

Regards,
Uday

No reply :frowning:

Hi Uday,

It might be good approach keep your playbooks separately, organized in roles.

And both will be called one-by-one by high-level simple playbook. So, something like this, when talking about structure of your project:

create_vm_with_java.yml

roles/

create_vm/

tasks/

handlers/

files/

vars/

defaults/

install_java/

tasks/

defaults/

meta/

and your top-level playbook create_vm_with_java.yml will have next content: