cleanup more old licensing cruft

This commit is contained in:
Ryan Petrello 2020-10-22 14:37:26 -04:00
parent be5ff0a088
commit 2df924ae78
No known key found for this signature in database
GPG Key ID: F2AA5F2122351777
2 changed files with 1 additions and 22 deletions

View File

@ -93,22 +93,10 @@ register(
)
def _load_default_license_from_file():
try:
license_file = os.environ.get('AWX_LICENSE_FILE', '/etc/tower/license')
if os.path.exists(license_file):
license_data = json.load(open(license_file))
logger.debug('Read license data from "%s".', license_file)
return license_data
except Exception:
logger.warning('Could not read license from "%s".', license_file, exc_info=True)
return {}
register(
'LICENSE',
field_class=fields.DictField,
default=_load_default_license_from_file,
default=lambda: {},
label=_('License'),
help_text=_('The license controls which features and functionality are '
'enabled. Use /api/v2/config/ to update or change '

File diff suppressed because one or more lines are too long