# Provision with Ansible from inside Docker

**URL:** <https://forum.ansible.com/t/provision-with-ansible-from-inside-docker/16766>\
**Category:** Ansible Project\
**Created:** [November 13, 2014, 7:25am UTC](https://forum.ansible.com/t/provision-with-ansible-from-inside-docker/16766 "2014-11-13T07:25:26Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Victor\_Lin](https://avatars.discourse-cdn.com/v4/letter/v/87869e/32.png) [@Victor\_Lin](https://forum.ansible.com/u/Victor_Lin)\
**Post date:** [November 13, 2014, 7:25am UTC](https://forum.ansible.com/t/provision-with-ansible-from-inside-docker/16766/1 "2014-11-13T07:25:26Z")

</div>

Hey guys,

I am using Ansible and Docker in a very interesting way, I think it would be useful for others, so I wrote an article about it

[http://victorlin.me/posts/2014/11/13/provision-with-ansible-from-inside-docker](http://victorlin.me/posts/2014/11/13/provision-with-ansible-from-inside-docker)

The very basic idea is to pack all Ansible runtimes/roles/playbooks/plugins into a docker image, and then you have a container for provisioning. I think this is really powerful, for example, you can run sometime like this:

sudo docker pull ansible-open-stack-swift

and

sudo docker run -it ansible-open-stack-swift …

then you can provision to either EC2 cluster or local machines, whatever you want. You even don’t need to install the Ansible runtime on your machine. With this idea in mind, not only software can be shipped as a container, the software for deployment can also be shipped as a container. In the community, we can build many interesting stuff, like Ansible image for launching the different clusters.

---

<div class="post-metadata">

**Author:** ![Michael\_DeHaan1](https://avatars.discourse-cdn.com/v4/letter/m/5e9695/32.png) [@Michael\_DeHaan1](https://forum.ansible.com/u/Michael_DeHaan1)\
**Post date:** [November 17, 2014, 9:17pm UTC](https://forum.ansible.com/t/provision-with-ansible-from-inside-docker/16766/2 "2014-11-17T21:17:44Z")

</div>

Thanks for sharing!

Related articles for those interested:

[http://www.ansible.com/blog/official-ansible-content-on-docker-hub](http://www.ansible.com/blog/official-ansible-content-on-docker-hub)

[http://ansible.com/docker](http://ansible.com/docker)
