mirror of
https://github.com/ansible/awx.git
synced 2026-05-20 07:17:40 -02:30
Improve the HashiCorp Vault KV name and field labels/help_text
This commit is contained in:
committed by
Jake McDermott
parent
9036ba492c
commit
89b731a0cb
@@ -6,27 +6,27 @@ from hvac import Client
|
|||||||
hashi_inputs = {
|
hashi_inputs = {
|
||||||
'fields': [{
|
'fields': [{
|
||||||
'id': 'url',
|
'id': 'url',
|
||||||
'label': 'Hashivault Server URL',
|
'label': 'Server URL',
|
||||||
'type': 'string',
|
'type': 'string',
|
||||||
'help_text': 'The Hashivault server url.'
|
'help_text': 'The URL to the HashiCorp Vault',
|
||||||
}, {
|
}, {
|
||||||
'id': 'secret_path',
|
'id': 'secret_path',
|
||||||
'label': 'Secret Path',
|
'label': 'Secret Path',
|
||||||
'type': 'string',
|
'type': 'string',
|
||||||
'help_text': 'The path to the secret.'
|
'help_text': 'The path to the secret e.g., /some-engine/some-secret/',
|
||||||
}, {
|
}, {
|
||||||
'id': 'secret_field',
|
'id': 'secret_field',
|
||||||
'label': 'Secret Field',
|
'label': 'Secret Field',
|
||||||
'type': 'string',
|
'type': 'string',
|
||||||
'help_text': 'The data field to access on the secret.'
|
'help_text': 'The name of the key to look up in the secret.',
|
||||||
}, {
|
}, {
|
||||||
'id': 'token',
|
'id': 'token',
|
||||||
'label': 'Token',
|
'label': 'Token',
|
||||||
'type': 'string',
|
'type': 'string',
|
||||||
'secret': True,
|
'secret': True,
|
||||||
'help_text': 'An access token for the Hashivault server.'
|
'help_text': 'The access token used to authenticate to the Vault server',
|
||||||
}],
|
}],
|
||||||
'required': ['url', 'secret_path', 'token'],
|
'required': ['url', 'secret_path', 'secret_field', 'token'],
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -45,4 +45,4 @@ def hashi_backend(**kwargs):
|
|||||||
return response['data']
|
return response['data']
|
||||||
|
|
||||||
|
|
||||||
hashivault_plugin = CredentialPlugin('Hashivault', inputs=hashi_inputs, backend=hashi_backend)
|
hashivault_plugin = CredentialPlugin('HashiCorp Vault KV Lookup', inputs=hashi_inputs, backend=hashi_backend)
|
||||||
|
|||||||
Reference in New Issue
Block a user