Before we start, we should first refer to the beginning of this chapter. We outlined the steps to create users and tenants within your OpenStack cloud. Here they are again for a quick reference:
Creating the user (with a corresponding complex secure password)
Creating the tenant for the user
Linking the user to the tenant while assigning that user with the appropriate role
The first step is to tackle the user creation portion of the process. Creating a user is a simple task in OpenStack, so why not add some administration flares to go along with it. Part of the process of creating a user is to assign that user an appropriate password. We will include this as part of the role that creates the user and tenant that we will assign the user to.
When creating a playbook, I normally start with creating roles to handle the administrative tasks needed. The role will contain all the executable code against OpenStack cloud. The playbook will contain the host to run the role...