* Allows the use of Private_Keys to be entered as a string instead of just a file. Making it possible to use VAULT to encrypt the key
* Fixed Issues auto check found
* Provide helpful information while avoiding credential exposure
* Restore original variable name :-)
* Fix a few other things
* Influence the default certificate_name in both cases
* Update documentation
* Add contributed docs
* Fix CI issue
@ -204,10 +204,14 @@ Every Ansible ACI module accepts the following parameters that influence the mod
Password for ``username`` to log on to the APIC, using password-based authentication.
private_key
Private key for ``username`` to log on to APIC, using signature-based authentication. *New in version 2.5*
Private key for ``username`` to log on to APIC, using signature-based authentication.
This could either be the raw private key content (include header/footer) or a file that stores the key content.
*New in version 2.5*
certificate_name
Name of the certificate in the ACI Web GUI. (Defaults to ``private_key`` file base name) *New in version 2.5*
Name of the certificate in the ACI Web GUI.
This defaults to either the ``username`` value or the ``private_key`` file base name).
*New in version 2.5*
timeout
Timeout value for socket-level communication.
@ -367,11 +371,70 @@ You need the following parameters with your ACI module(s) for it to work:
private_key: pki/admin.key
certificate_name: admin # This could be left out !
or you can use the private key content:
..code-block:: yaml
:emphasize-lines:2,3
username: admin
private_key: |
-----BEGIN PRIVATE KEY-----
<<your private key content>>
-----END PRIVATE KEY-----
certificate_name: admin # This could be left out !
..hint:: If you use a certificate name in ACI that matches the private key's basename, you can leave out the ``certificate_name`` parameter like the example above.
Using Ansible Vault to encrypt the private key
``````````````````````````````````````````````
..versionadded:: 2.8
To start, encrypt the private key and give it a strong password.
..code-block:: bash
ansible-vault encrypt admin.key
Use a text editor to open the private-key. You should have an encrypted cert now.
certificate_name: admin # This could be left out !
When running the playbook, use "--ask-vault-pass" to decrypt the private key.
..code-block:: bash
ansible-playbook site.yaml --ask-vault-pass
More information
````````````````
Detailed information about Signature-based Authentication is available from `Cisco APIC Signature-Based Transactions <https://www.cisco.com/c/en/us/td/docs/switches/datacenter/aci/apic/sw/kb/b_KB_Signature_Based_Transactions.html>`_.
- Detailed information about Signature-based Authentication is available from `Cisco APIC Signature-Based Transactions <https://www.cisco.com/c/en/us/td/docs/switches/datacenter/aci/apic/sw/kb/b_KB_Signature_Based_Transactions.html>`_.
- More information on Ansible Vault can be found on the :ref:`Ansible Vault <vault>` page.