Hi Guy, 
First you need a way to refer to your servers in the required release 
order. Easy way is to just have them as a group in your host file such as:

[servers]
server1
server2
server3
...
serverN

Then in your rolling deploy playbook, you refer to this group as hosts, and 
use serial=1 if you would like Ansible to finish all apps in one server 
before moving on to the next one.

To force the app order, you can create task lists for each deploy, and then 
include them in order, such as:

hosts: servers
serial:1
.
.
.
tasks:
   - include : deploy_app1
   - include: deploy_app2
   - include: deploy_app3

Hope it helps !




On Wednesday, July 29, 2015 at 5:03:14 PM UTC-4, Guy Matz wrote:
>
> Hello!
> I have the requirement to perform rolling deploys to groups of servers at 
> a time, e.g. the first set of servers - app1_server_1, app2_server_1, 
> app3_server1 - first, then the second set - app1_server2, app2_server2, 
> app3_server2 - then the third set, app1_server3, app2_server3, 
> app3_server3, etc.
>
> Anyone know of a good way to do this in ansible?
>
> Thanks a lot,
> Guy
>

-- 
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 [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/2f5e106b-ede6-483a-bc66-0c7f7d70aade%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to