Deprecated in 2.0. Use os_keypair instead
Add or Remove key pair from nova .
- python >= 2.6
- python-novaclient
parameter | required | default | choices | comments |
---|---|---|---|---|
auth_url |
no | http://127.0.0.1:35357/v2.0/ | The keystone url for authentication | |
login_password |
yes | yes | Password of login user | |
login_tenant_name |
yes | yes | The tenant name of the login user | |
login_username |
yes | admin | login username to authenticate to keystone | |
name |
yes | None | Name that has to be given to the key pair | |
public_key |
no | None | The public key that would be uploaded to nova and injected to vm's upon creation | |
region_name |
no | None | Name of the region | |
state |
no | present |
|
Indicate desired state of the resource |
# Creates a key pair with the running users public key - nova_keypair: state=present login_username=admin login_password=admin login_tenant_name=admin name=ansible_key public_key={{ lookup('file','~/.ssh/id_rsa.pub') }} # Creates a new key pair and the private key returned after the run. - nova_keypair: state=present login_username=admin login_password=admin login_tenant_name=admin name=ansible_key
For help in developing on modules, should you be so inclined, please read Community Information & Contributing, Helping Testing PRs and Developing Modules.