# Provisioning OpenStack with Ansible from scratch, missing modules?

**URL:** <https://forum.ansible.com/t/provisioning-openstack-with-ansible-from-scratch-missing-modules/20850>\
**Category:** Ansible Project\
**Tags:** ubuntu\
**Created:** [March 12, 2016, 6:40am UTC](https://forum.ansible.com/t/provisioning-openstack-with-ansible-from-scratch-missing-modules/20850 "2016-03-12T06:40:41Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Thiago\_Martins](https://avatars.discourse-cdn.com/v4/letter/t/96bed5/32.png) [@Thiago\_Martins](https://forum.ansible.com/u/Thiago_Martins)\
**Post date:** [March 12, 2016, 6:40am UTC](https://forum.ansible.com/t/provisioning-openstack-with-ansible-from-scratch-missing-modules/20850/1 "2016-03-12T06:40:41Z")

</div>

Hey guys,

Currently, I’m developing an OpenStack Mitaka Ansible automation for Ubuntu 16.04.

I’m using a lot of “command / shell” Ansible modules and I would like to avoid it, and start using native Ansible OS modules.

However, I can’t find native modules for creating OpenStack Services, Projects, Users, Roles and Endpoints… Am I missing something?

This is how I am doing it today (looks ugly but it works for Mitaka b2):

[https://github.com/tmartinx/svauto/blob/dev/ansible/roles/os\_openstack\_data/tasks/openstack-services.yml](https://github.com/tmartinx/svauto/blob/dev/ansible/roles/os_openstack_data/tasks/openstack-services.yml)

[https://github.com/tmartinx/svauto/blob/dev/ansible/roles/os\_openstack\_data/tasks/openstack-pur.yml](https://github.com/tmartinx/svauto/blob/dev/ansible/roles/os_openstack_data/tasks/openstack-pur.yml)

[https://github.com/tmartinx/svauto/blob/dev/ansible/roles/os\_openstack\_data/tasks/openstack-endpoints.yml](https://github.com/tmartinx/svauto/blob/dev/ansible/roles/os_openstack_data/tasks/openstack-endpoints.yml)

I think that it would be super awesome to use native Ansible modules to do all of this, is it possible?

Thanks!  
Thiago

---

<div class="post-metadata">

**Author:** ![Thiago\_Martins](https://avatars.discourse-cdn.com/v4/letter/t/96bed5/32.png) [@Thiago\_Martins](https://forum.ansible.com/u/Thiago_Martins)\
**Post date:** [March 12, 2016, 6:55am UTC](https://forum.ansible.com/t/provisioning-openstack-with-ansible-from-scratch-missing-modules/20850/2 "2016-03-12T06:55:41Z")

</div>

Right, it is Friday night, looong week and I’m a bit tired… =P

I just found those modules:

[https://docs.ansible.com/ansible/os\_project\_module.html](https://docs.ansible.com/ansible/os_project_module.html)

[https://docs.ansible.com/ansible/os\_user\_module.html](https://docs.ansible.com/ansible/os_user_module.html)

That apparently, can help me to create initial Projects and Users, but, what about Services, Roles and Endpoints?

BTW, I’m using Ansible 2.0 from Ubuntu 16.04…

Cheers!  
Thiago

---

<div class="post-metadata">

**Author:** ![Larry\_Smith1](https://avatars.discourse-cdn.com/v4/letter/l/d26b3c/32.png) [@Larry\_Smith1](https://forum.ansible.com/u/Larry_Smith1)\
**Post date:** [March 14, 2016, 12:57am UTC](https://forum.ansible.com/t/provisioning-openstack-with-ansible-from-scratch-missing-modules/20850/3 "2016-03-14T00:57:17Z")

</div>

I did this exact same thing a few months ago but using Kilo and Ubuntu 14.04LTS which may be of some use to you. However I did use some of the modules which have been replaced but should not be too hard to make those changes. Again just sharing this as it may be of some use for you.

[https://github.com/mrlesmithjr/ansible-openstack](https://github.com/mrlesmithjr/ansible-openstack)

---

<div class="post-metadata">

**Author:** ![David\_Shrewsbury1](https://avatars.discourse-cdn.com/v4/letter/d/7ab992/32.png) [@David\_Shrewsbury1](https://forum.ansible.com/u/David_Shrewsbury1)\
**Post date:** [March 14, 2016, 1:34pm UTC](https://forum.ansible.com/t/provisioning-openstack-with-ansible-from-scratch-missing-modules/20850/4 "2016-03-14T13:34:46Z")

</div>

We are continually working on adding new modules. Some exist as PRs right now and will hopefully show up  
in the Ansible 2.1 release.

-Dave

---

<div class="post-metadata">

**Author:** ![Thiago\_Martins](https://avatars.discourse-cdn.com/v4/letter/t/96bed5/32.png) [@Thiago\_Martins](https://forum.ansible.com/u/Thiago_Martins)\
**Post date:** [March 16, 2016, 5:26pm UTC](https://forum.ansible.com/t/provisioning-openstack-with-ansible-from-scratch-missing-modules/20850/5 "2016-03-16T17:26:48Z")

</div>

Thanks for sharing Larry! I’ll take a look at your automation… Cheers!

---

<div class="post-metadata">

**Author:** ![Thiago\_Martins](https://avatars.discourse-cdn.com/v4/letter/t/96bed5/32.png) [@Thiago\_Martins](https://forum.ansible.com/u/Thiago_Martins)\
**Post date:** [March 16, 2016, 5:27pm UTC](https://forum.ansible.com/t/provisioning-openstack-with-ansible-from-scratch-missing-modules/20850/6 "2016-03-16T17:27:23Z")

</div>

Sounds awesome David! I’m very interested in OpenStack Ansible native modules… Thanks!

---

<div class="post-metadata">

**Author:** ![Michael\_Gale](https://avatars.discourse-cdn.com/v4/letter/m/bbe5ce/32.png) [@Michael\_Gale](https://forum.ansible.com/u/Michael_Gale)\
**Post date:** [March 17, 2016, 1:51am UTC](https://forum.ansible.com/t/provisioning-openstack-with-ansible-from-scratch-missing-modules/20850/7 "2016-03-17T01:51:33Z")

</div>

Hey,

Have you considered using something like:  
[https://github.com/openstack/openstack-ansible](https://github.com/openstack/openstack-ansible)

Here are the docs to the above repo: [http://docs.openstack.org/developer/openstack-ansible/install-guide/index.html](http://docs.openstack.org/developer/openstack-ansible/install-guide/index.html)

Michael

---

<div class="post-metadata">

**Author:** ![Thiago\_Martins](https://avatars.discourse-cdn.com/v4/letter/t/96bed5/32.png) [@Thiago\_Martins](https://forum.ansible.com/u/Thiago_Martins)\
**Post date:** [March 17, 2016, 10:41pm UTC](https://forum.ansible.com/t/provisioning-openstack-with-ansible-from-scratch-missing-modules/20850/8 "2016-03-17T22:41:01Z")

</div>

Hello Michael,

Yes, I have considered OpenStack Ansible project, however, they are deploying OpenStack from Git and by using Python Pip directly (and many containers), no support for OpenvSwitch, neither DPDK, only Linux Bridges…

On the other hand, I am using native Ubuntu Xenial 16.04 Mitaka packages, because I prefer to keep it simple and also, I prefer to stick with 100% Ubuntu packages.

Also, I need OpenStack with OpenvSwitch powered by DPDK, which comes by default on Xenial, this is a must for my project.

So, unfortunately, OpenStack Ansible is not an option for me… =/

Best,  
Thiago

---

<div class="post-metadata">

**Author:** ![Curtis](https://avatars.discourse-cdn.com/v4/letter/c/58956e/32.png) [@Curtis](https://forum.ansible.com/u/Curtis)\
**Post date:** [March 24, 2016, 8:45pm UTC](https://forum.ansible.com/t/provisioning-openstack-with-ansible-from-scratch-missing-modules/20850/9 "2016-03-24T20:45:18Z")

</div>

> Hello Michael,
> 
> Yes, I have considered OpenStack Ansible project, however, they are  
> deploying OpenStack from Git and by using Python Pip directly (and many  
> containers), no support for OpenvSwitch, neither DPDK, only Linux Bridges...

There's been some work in OpenStack-Ansible to add OpenVSwitch. I'm  
going to hopefully continue this work to add the ability to use  
OpenVSwitch with OpenStack-Ansible. That said certainly  
OpenStack-Ansible is a fairly large framework.

> On the other hand, I am using native Ubuntu Xenial 16.04 Mitaka packages,  
> because I prefer to keep it simple and also, I prefer to stick with 100%  
> Ubuntu packages.
> 
> Also, I need OpenStack with OpenvSwitch powered by DPDK, which comes by  
> default on Xenial, this is a must for my project.

I believe, and I just noticed this today, that the Ubuntu Cloud  
Archive for Liberty contains a packaged OpenVSwitch with DPDK for  
Ubuntu 14.04/Trusty.

Thanks,  
Curtis.
