OpenStack Modules

The New Era

AnsibleFest SFO 2015

Jesse Keating

@iamjkeating

Senior Software Engineer, OpenStack Relase Lead

 

In the beginning...

nova.py inventory

  • Version 0.8 (2012)
  • Rackspace tested only
  • Required Grizzly or later
  • Marco Vito

First Rackspace Module (rax)

  • Version 1.2 (2013)
  • Compute only
  • Required pyrax
  • Jesse Keating (hey that's me!)
  • Also a rax inventory plugin

First OpenStack modules

  • Version 1.2 (2013)
  • nova_compute, nova_keypair
  • quantum_
    • floating_ip
    • floating_ip_associate
    • network
    • router
    • router_gateway
    • router_interface
    • subnet
  • glance_image
  • keystone_user
  • Benno Joy

rax_network, rax_facts

  • Version 1.4 (2013)
  • Rackspace only (pyrax)
  • Part of a refactor of rax module
  • Chris Laco, Matt Martz

Common code for rax*

  • Version 1.5 (2013)
  • Reduced code count a lot
  • Created model for shared code
  • Matt Martz and others

rax_keypair

  • Version 1.5 (2013)
  • Rackspace verison of nova_keypair
  • Matt Martz

Object Storage modules

  • Version 1.5 (2013)
  • rax_files
  • rax_files_objects
  • Paul Durivage

rax_queue

  • Version 1.5 (2013)
  • Marconi, but Rackspace
  • Chris Laco

Block Storage

  • Version 1.6 (2014)
  • rax_cbs
  • rax_cbs_attachments
  • Chris Laco, Matt Martz

nova_group, nova_fip

  • Version 1.6 (2014)
  • Used novaclient
  • Could load creds from ENV
  • John Dewey

DBaaS

  • Version 1.8 (2014)
  • rax_cdb
  • rax_cdb_database
  • rax_cdb_user
  • Simon Jaillet

Core and Extras

Time passes...

OpenStack Infra

Monty Taylor

OpenStack Infra

  • CI for all OpenStack project changes
  • Uses multiple Public Cloud providors
  • Adding features to existing modules
  • Unhappy with divergence in workflows

Deprecation

Enter os_*

New modules

  • os_
    • auth
    • client_config
    • floating_ip
    • image
    • image_facts
    • ironic
    • ironic_node
    • keypair
    • network
    • networks_facts
    • nova_flavor
    • port
    • router

New modules

  • os_
    • security_group
    • security_group_rule
    • server
    • server_facts
    • server_volume
    • subnet
    • subnets_facts
    • user
    • user_group
    • volume

Goals

  • Shared code
  • Shared docs
  • Generic naming for user actions
  • Specific naming for project / admin actions
  • Just Works(tm) across multiple vendors
  • Replace existing functionality
  • Add more functionality
  • Part of 2.0

Common Code

  • Modules code
    • lib/ansible/module_utils/openstack.py
  • Documentation
    • lib/ansible/utils/module_docs_fragments/openstack.py

Meet Shade

Why Shade?

  • Users had to know cloud specifics
  • OpenStack breaks APIs
  • Basics are complex
  • Client libs exist for service to service

Adding new functionality

Existing PRs

  • Core and Extras
  • Please test and review

New PRs

  • Use shade
  • Learn from existing os_*
  • New modules -> extras
  • PR to shade for new workarounds
  • PR to ansible for shared code/docs

Questions?

Mastering Ansible

Made with Slides.com