adding additional example and clarification (#47224)
The kind: paramter is missing from the original example (which won't actually work). The organization needs to be listed as required (if you don't list it, you will get an error). Also adding additional example using the tower_username and tower_password method.
This commit is contained in:
parent
c809560385
commit
81d22dc304
1 changed files with 15 additions and 1 deletions
|
@ -42,9 +42,10 @@ options:
|
||||||
organization:
|
organization:
|
||||||
description:
|
description:
|
||||||
- Organization that should own the credential.
|
- Organization that should own the credential.
|
||||||
|
required: True
|
||||||
kind:
|
kind:
|
||||||
description:
|
description:
|
||||||
- Type of credential being added.
|
- Type of credential being added. The ssh choice refers to a Tower Machine credential.
|
||||||
required: True
|
required: True
|
||||||
choices: ["ssh", "vault", "net", "scm", "aws", "vmware", "satellite6", "cloudforms", "gce", "azure_rm", "openstack", "rhv", "insights", "tower"]
|
choices: ["ssh", "vault", "net", "scm", "aws", "vmware", "satellite6", "cloudforms", "gce", "azure_rm", "openstack", "rhv", "insights", "tower"]
|
||||||
host:
|
host:
|
||||||
|
@ -118,6 +119,7 @@ EXAMPLES = '''
|
||||||
name: Team Name
|
name: Team Name
|
||||||
description: Team Description
|
description: Team Description
|
||||||
organization: test-org
|
organization: test-org
|
||||||
|
kind: ssh
|
||||||
state: present
|
state: present
|
||||||
tower_config_file: "~/tower_cli.cfg"
|
tower_config_file: "~/tower_cli.cfg"
|
||||||
|
|
||||||
|
@ -131,6 +133,18 @@ EXAMPLES = '''
|
||||||
password: secret
|
password: secret
|
||||||
ssh_key_data: "{{ lookup('file', '/tmp/id_rsa') }}"
|
ssh_key_data: "{{ lookup('file', '/tmp/id_rsa') }}"
|
||||||
ssh_key_unlock: "passphrase"
|
ssh_key_unlock: "passphrase"
|
||||||
|
|
||||||
|
- name: Add Credential Into Tower
|
||||||
|
tower_credential:
|
||||||
|
name: Workshop Credential
|
||||||
|
ssh_key_data: "/home/{{ansible_user}}/.ssh/aws-private.pem"
|
||||||
|
kind: ssh
|
||||||
|
organization: Default
|
||||||
|
tower_username: admin
|
||||||
|
tower_password: ansible
|
||||||
|
tower_host: https://localhost
|
||||||
|
run_once: true
|
||||||
|
delegate_to: localhost
|
||||||
'''
|
'''
|
||||||
|
|
||||||
import os
|
import os
|
||||||
|
|
Loading…
Reference in a new issue