mirror of
https://github.com/ansible/awx.git
synced 2026-01-17 12:41:19 -03:30
force PENDO_TRACKING_STATE to be readonly for the open source license
see: #6890
This commit is contained in:
parent
3856431da1
commit
937e90d342
@ -10,6 +10,8 @@ from django.core.exceptions import ImproperlyConfigured
|
||||
from django.utils.text import slugify
|
||||
from django.utils.translation import ugettext_lazy as _
|
||||
|
||||
from awx.conf.license import get_license
|
||||
|
||||
logger = logging.getLogger('awx.conf.registry')
|
||||
|
||||
__all__ = ['settings_registry']
|
||||
@ -162,6 +164,11 @@ class SettingsRegistry(object):
|
||||
pass
|
||||
except:
|
||||
logger.warning('Unable to retrieve default value for setting "%s".', setting, exc_info=True)
|
||||
|
||||
# `PENDO_TRACKING_STATE` is disabled for the open source awx license
|
||||
if setting == 'PENDO_TRACKING_STATE' and get_license().get('license_type') == 'open':
|
||||
field_instance.read_only = True
|
||||
|
||||
return field_instance
|
||||
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user