TripleO and Ansible: config-download with Ansible Tower (part 3)

In my 2 previous posts, I’ve talked about TripleO’s config-download. If you
haven’t had a chance to read those yet, I suggest checking them out here and
here.

One of the nice things about config-download is that it integrates nicely with
other Ansible based tooling. In particular, Ansible Tower (or Ansible AWX) can
be used to drive applying the overcloud configuration. For users and
operators who are already familiar with Tower, this provides a nice way to
manage and report on the overcloud deployment status with TripleO and Tower.

At a high level, this integration is broken down into the following steps on
the TripleO undercloud:

  1. Create the Heat stack
  2. Run openstack overcloud config download to download the ansible
    playbooks from Heat
  3. Run tripleo-ansible-inventory to create the Ansible inventory file
  4. Since Ansible Tower uses git or other (SCM’s) to synchronize and manage
    Ansible project directories, we create a git repo from the config-download
    directory on the undercloud.

Switching over to Ansible Tower, we then:

  1. Create an organization
  2. Create SCM (git) credentials and machine credentials
  3. Create the Ansible project, pointing it at the git repository we created on
    the undercloud
  4. Create the inventory and inventory source, pointing it at the inventory file
    within the project directory we created with tripleo-ansible-inventory.
  5. Create a Job Template to run deploy_steps_playbook.yaml from the project
  6. Launch the Job Template

When the job finishes, we have a deployed and configured overcloud ready for
use by tenants.

Here’s a video of the demo showing the above steps:

https://slagle.fedorapeople.org/tripleo-config-download-ansible-tower.mp4

Of course, we wouldn’t want to manually go through those steps every time. We
can instead automate them with an ansible playbook, and then execute the
playbook from the undercloud, or a different management node. An example
playbook that automates all the steps above can be seen here:

https://github.com/slagle/tripleo-config-download-ansible-tower/blob/master/config-download.yaml

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s