Mutiple Version Maintain in PlayBooks

30 views
Skip to first unread message

siva kumar

unread,
May 6, 2014, 7:14:15 AM5/6/14
to ansible...@googlegroups.com
Hi ,


We are using ansible playbook for new package installation .


How to maintain mutiple version of packages ( jdk1.6 , jdk1.6.1 and jdk1.6.2) .


We need to write new role like
role / jdk1.6
role / jdk1.6.1
role / jdk1.6.2

OR

Can we handle single role ? ( Is it possible )

role / jdk


Please let me know - which one is best ?


Thanks,
S.Sivakumar


Brian Coca

unread,
May 6, 2014, 8:42:37 AM5/6/14
to ansible...@googlegroups.com
I use role's default/main.yml to set a version: variable, which can be overriden when calling the role.​

Michael DeHaan

unread,
May 6, 2014, 8:59:22 AM5/6/14
to ansible...@googlegroups.com
See http://docs.ansible.com/playbooks_roles.html#roles and the following example of passing values to parameterized roles:

---

- hosts: webservers
  roles:
    - common
    - { role: foo_app_instance, dir: '/opt/a',  port: 5000 }
    - { role: foo_app_instance, dir: '/opt/b',  port: 5001 }




On Tue, May 6, 2014 at 8:42 AM, Brian Coca <bria...@gmail.com> wrote:
I use role's default/main.yml to set a version: variable, which can be overriden when calling the role.​

--
You received this message because you are subscribed to the Google Groups "Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ansible-proje...@googlegroups.com.
To post to this group, send email to ansible...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/CADn%2BHszJWd3xYYA8ei%3D3qQRAN7PNodcEKB%3DSbB%2BXHPdr3v6PUw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages