Add the ability to specify K8S/OCP credentials on a Job Template

see: https://github.com/ansible/awx/issues/5735
This commit is contained in:
Ryan Petrello
2020-07-15 16:57:42 -04:00
parent cd6df9299f
commit 0b221a42c0
8 changed files with 44 additions and 19 deletions

View File

@@ -1169,7 +1169,18 @@ ManagedCredentialType(
'multiline': True,
}],
'required': ['host', 'bearer_token'],
}
},
injectors={
'file': {
'template': '{{ ssl_ca_cert }}'
},
'env': {
'K8S_AUTH_HOST': '{{ host }}',
'K8S_AUTH_API_KEY': '{{ bearer_token }}',
'K8S_AUTH_VERIFY_SSL': '{{ verify_ssl }}',
'K8S_AUTH_SSL_CA_CERT': '{{ tower.filename }}',
},
},
)