# Ansible for Openstack

**URL:** <https://forum.ansible.com/t/ansible-for-openstack/30900>\
**Category:** Ansible Project\
**Created:** [July 30, 2019, 8:26am UTC](https://forum.ansible.com/t/ansible-for-openstack/30900 "2019-07-30T08:26:29Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rahul\_Kumar1](https://avatars.discourse-cdn.com/v4/letter/r/da6949/32.png) [@Rahul\_Kumar1](https://forum.ansible.com/u/Rahul_Kumar1)\
**Post date:** [July 30, 2019, 8:26am UTC](https://forum.ansible.com/t/ansible-for-openstack/30900/1 "2019-07-30T08:26:29Z")

</div>

Hi Team,  
Currently I am trying to provision Openstack resources using Ansible with sample template snippet as below:  
os\_server:  
state: present  
cloud: smscrhosp  
name: test-instance  
image: CentOS-7-x86\_64-GenericCloud  
key\_name: mariachi-pub-key  
timeout: 200  
flavor: m1.small  
network: test-network  
auto\_ip: yes  
security\_groups:\\\\

I want to know , if our topology needs 10 nodes , then do we need to write this os\_server 10 times in Playbook  
or is there any better way to achive same?

Rahul

---

<div class="post-metadata">

**Author:** ![Dick\_Visser](https://avatars.discourse-cdn.com/v4/letter/d/d9b06d/32.png) [@Dick\_Visser](https://forum.ansible.com/u/Dick_Visser)\
**Post date:** [July 30, 2019, 11:36am UTC](https://forum.ansible.com/t/ansible-for-openstack/30900/2 "2019-07-30T11:36:33Z")

</div>

Use a loop to repeat the task as many times as you need
