Can someone provide a minimal working example of ansible role dependencies? -


i trying use ansible's dependencies feature cannot work. provide minimal example of role depends on role uses dependencies feature eg:

--- dependencies: - { role: common }

many thanks.

you should able use if put content specified in question in file:

<your-project-home>/roles/webservers/meta/main.yml  

make sure common role exists in:

<your-project-home>/roles/common 

make sure project structure looks this:

yourplaybook.yml roles/    common/    webservers/ 

yourplaybook.yml should this:

--- - hosts:   roles:      - webservers 

then call playbook this:

ansible-playbook -i ./inventory-file yourplaybook.yml 

Comments

Popular posts from this blog

android - Get AccessToken using signpost OAuth without opening a browser (Two legged Oauth) -

org.mockito.exceptions.misusing.InvalidUseOfMatchersException: mockito -

google shop client API returns 400 bad request error while adding an item -