Add a new extra_credentials endpoint for Jobs and JobTemplates

additionally, add backwards compatible support for `cloud_credential`
and `network_credential` in /api/v1/job_templates/ and /api/v1/jobs/.

see: #5807
This commit is contained in:
Ryan Petrello
2017-05-03 11:48:01 -04:00
parent accf7cdea2
commit d0a848d49a
8 changed files with 349 additions and 7 deletions

View File

@@ -215,6 +215,12 @@ def credential(credentialtype_aws):
inputs={'username': 'something', 'password': 'secret'})
@pytest.fixture
def net_credential(credentialtype_net):
return Credential.objects.create(credential_type=credentialtype_net, name='test-cred',
inputs={'username': 'something', 'password': 'secret'})
@pytest.fixture
def machine_credential(credentialtype_ssh):
return Credential.objects.create(credential_type=credentialtype_ssh, name='machine-cred',