From 2e2cd7f2de52a02a7bbf343f26bf8d0177dcdec3 Mon Sep 17 00:00:00 2001 From: Patrick Uiterwijk Date: Thu, 7 Mar 2024 22:07:03 +0700 Subject: Implement project pulling from Azure DevOps using Service Principals (#14628) * Credential Lookup with multiple types Allow looking up a credential with one of multiple type IDs. * Allow Azure cred for SCM Allow selecting an Azure Resource Manager credential for Git-based SCMs. This is in order to enable using Azure Service Principals for project updates. * Implement Azure Service Principal Git This adds support for using an Azure Service Principal for project updates. --------- Signed-off-by: Patrick Uiterwijk --- awxkit/awxkit/api/pages/projects.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'awxkit') diff --git a/awxkit/awxkit/api/pages/projects.py b/awxkit/awxkit/api/pages/projects.py index 125f452637..845d112cea 100644 --- a/awxkit/awxkit/api/pages/projects.py +++ b/awxkit/awxkit/api/pages/projects.py @@ -50,7 +50,7 @@ class Project(HasCopy, HasCreate, HasNotifications, UnifiedJobTemplate): def create_payload(self, name='', description='', scm_type='git', scm_url='', scm_branch='', organization=Organization, credential=None, **kwargs): if credential: if isinstance(credential, Credential): - if credential.ds.credential_type.namespace not in ('scm', 'insights'): + if credential.ds.credential_type.namespace not in ('scm', 'insights', 'azure_rm'): credential = None # ignore incompatible credential from HasCreate dependency injection elif credential in (Credential,): credential = (Credential, dict(credential_type=(True, dict(kind='scm')))) -- cgit v1.2.3