# Travis for Ansible

**URL:** <https://forum.ansible.com/t/travis-for-ansible/12607>\
**Category:** Ansible Project\
**Created:** [March 30, 2013, 8:27pm UTC](https://forum.ansible.com/t/travis-for-ansible/12607 "2013-03-30T20:27:06Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Tin\_Tvrtkovic](https://avatars.discourse-cdn.com/v4/letter/t/bc8723/32.png) [@Tin\_Tvrtkovic](https://forum.ansible.com/u/Tin_Tvrtkovic)\
**Post date:** [March 30, 2013, 8:27pm UTC](https://forum.ansible.com/t/travis-for-ansible/12607/1 "2013-03-30T20:27:06Z")

</div>

Hey guys,

it occured to me it might be interesting to set up Travis for Ansible.

Travis is a (free) continuous integration service for open source projects. Without getting too much into technical details, when set up properly, Travis will watch the project repository for updates (commits), and trigger a “build” when an update is encountered.

A build can do many things, but I’ve just set it up to run make tests; ideally, we would also run static analysis (pep8, pylint, pyflakes) on the code as well. When a build fails, emails can be sent out.

Anyway, I’ve gone ahead and set it up for my forked repo of Ansible. (I’ve done it just to see how it works; I’m very familiar with the practice of continuous integration and CI servers like Jenkins, so I wanted to check out how Travis works. If you guys don’t want to do this it’s no big deal.)

You can see what a build looks like here: [https://travis-ci.org/Tinche/ansible-ci/builds/5926612](https://travis-ci.org/Tinche/ansible-ci/builds/5926612)

The point of this is that the devs get notified when tests start failing (or pylint starts complaining, if someone sets it up). This sounds like an easy step in the SQA dimension for Ansible. There are more things that can be done for SQA purposes, but this is a low-hanging fruit and a good stepping board, I think. Also, you get to put a nice “Build status: passing” in the github README, so potential users can inspect the builds and be reassured.

If you guys think this is an interesting idea, I’d be happy to help out. All the tests passed on first build except one (the git module test) which can and should be easily fixed. You’d basically need to pull something from me (a very basic .travis.yml file, and the git test fix), register at Travis (with a github account), and set up a service hook for the Ansible repository to push notifications to Travis.

---

<div class="post-metadata">

**Author:** ![Michel\_Blanc1](https://avatars.discourse-cdn.com/v4/letter/m/fbc32d/32.png) [@Michel\_Blanc1](https://forum.ansible.com/u/Michel_Blanc1)\
**Post date:** [March 30, 2013, 8:33pm UTC](https://forum.ansible.com/t/travis-for-ansible/12607/2 "2013-03-30T20:33:03Z")

</div>

Hi Tin,

Been there, tried that, and I wasn't the only one :  
[https://github.com/ansible/ansible/issues/search?q=travis](https://github.com/ansible/ansible/issues/search?q=travis)

I also think it's a good idea.

May be with the growing number of contribs, this might be reconsidered.

M

---

<div class="post-metadata">

**Author:** ![Lorin\_Hochstein1](https://avatars.discourse-cdn.com/v4/letter/l/ce73a5/32.png) [@Lorin\_Hochstein1](https://forum.ansible.com/u/Lorin_Hochstein1)\
**Post date:** [March 30, 2013, 8:35pm UTC](https://forum.ansible.com/t/travis-for-ansible/12607/3 "2013-03-30T20:35:52Z")

</div>

As another person who tried, I also hope Michael will reconsider this. (Or,  
alternatively, provide another solution for CI testing).

Lorin

---

<div class="post-metadata">

**Author:** ![Tin\_Tvrtkovic](https://avatars.discourse-cdn.com/v4/letter/t/bc8723/32.png) [@Tin\_Tvrtkovic](https://forum.ansible.com/u/Tin_Tvrtkovic)\
**Post date:** [March 30, 2013, 8:38pm UTC](https://forum.ansible.com/t/travis-for-ansible/12607/4 "2013-03-30T20:38:11Z")

</div>

Oh wow, guess I should have searched first. But as I said, I was curious how it all works so I don’t consider it wasted effort.

I think it’s unfortunate if Michael still isn’t interested in Travis; it’s a very simple step and I think it definitely has value for the project.

---

<div class="post-metadata">

**Author:** ![Michael\_DeHaan2](https://avatars.discourse-cdn.com/v4/letter/m/da6949/32.png) [@Michael\_DeHaan2](https://forum.ansible.com/u/Michael_DeHaan2)\
**Post date:** [March 31, 2013, 2:18pm UTC](https://forum.ansible.com/t/travis-for-ansible/12607/5 "2013-03-31T14:18:34Z")

</div>

We won't be using Travis.

Later, down the road, we'll have a real integration test farm that can  
actually test things on multiple distributions and that is more easily  
extensible.
