mirror of
https://github.com/ansible/awx.git
synced 2026-03-10 22:19:28 -02:30
Add read-only settings for IS_K8S
This commit is contained in:
committed by
Shane McDonald
parent
77b0b9a4e3
commit
f08bf4766d
@@ -692,6 +692,15 @@ register(
|
|||||||
unit=_('seconds'),
|
unit=_('seconds'),
|
||||||
)
|
)
|
||||||
|
|
||||||
|
register(
|
||||||
|
'IS_K8S',
|
||||||
|
field_class=fields.BooleanField,
|
||||||
|
read_only=True,
|
||||||
|
category=_('System'),
|
||||||
|
category_slug='system',
|
||||||
|
help_text=_('Indicates whether the instance is part of a kubernetes-based deployment.'),
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
def logging_validate(serializer, attrs):
|
def logging_validate(serializer, attrs):
|
||||||
if not serializer.instance or not hasattr(serializer.instance, 'LOG_AGGREGATOR_HOST') or not hasattr(serializer.instance, 'LOG_AGGREGATOR_TYPE'):
|
if not serializer.instance or not hasattr(serializer.instance, 'LOG_AGGREGATOR_HOST') or not hasattr(serializer.instance, 'LOG_AGGREGATOR_TYPE'):
|
||||||
|
|||||||
Reference in New Issue
Block a user