mirror of
https://github.com/ZwareBear/awx.git
synced 2026-05-17 06:58:36 -05:00
Merge pull request #1635 from matburt/new_azure_inventory_and_credentials
Implement Azure RM creds and inventory
This commit is contained in:
@@ -41,7 +41,8 @@ class Credential(PasswordFieldsModel, CommonModelNameNotUnique, ResourceMixin):
|
||||
('foreman', _('Red Hat Satellite 6')),
|
||||
('cloudforms', _('Red Hat CloudForms')),
|
||||
('gce', _('Google Compute Engine')),
|
||||
('azure', _('Microsoft Azure')),
|
||||
('azure', _('Microsoft Azure Classic (deprecated)')),
|
||||
('azure_rm', _('Microsoft Azure Resource Manager')),
|
||||
('openstack', _('OpenStack')),
|
||||
]
|
||||
|
||||
@@ -55,7 +56,7 @@ class Credential(PasswordFieldsModel, CommonModelNameNotUnique, ResourceMixin):
|
||||
]
|
||||
|
||||
PASSWORD_FIELDS = ('password', 'security_token', 'ssh_key_data', 'ssh_key_unlock',
|
||||
'become_password', 'vault_password')
|
||||
'become_password', 'vault_password', 'secret')
|
||||
|
||||
class Meta:
|
||||
app_label = 'main'
|
||||
@@ -168,6 +169,30 @@ class Credential(PasswordFieldsModel, CommonModelNameNotUnique, ResourceMixin):
|
||||
default='',
|
||||
help_text=_('Vault password (or "ASK" to prompt the user).'),
|
||||
)
|
||||
client = models.CharField(
|
||||
max_length=128,
|
||||
blank=True,
|
||||
default='',
|
||||
help_text=_('Client Id or Application Id for the credential'),
|
||||
)
|
||||
secret = models.CharField(
|
||||
max_length=1024,
|
||||
blank=True,
|
||||
default='',
|
||||
help_text=_('Secret Token for this credential'),
|
||||
)
|
||||
subscription = models.CharField(
|
||||
max_length=1024,
|
||||
blank=True,
|
||||
default='',
|
||||
help_text=_('Subscription identifier for this credential'),
|
||||
)
|
||||
tenant = models.CharField(
|
||||
max_length=1024,
|
||||
blank=True,
|
||||
default='',
|
||||
help_text=_('Tenant identifier for this credential'),
|
||||
)
|
||||
owner_role = ImplicitRoleField(
|
||||
role_name='Credential Owner',
|
||||
role_description='Owner of the credential',
|
||||
|
||||
Reference in New Issue
Block a user