diff --git a/awx/api/serializers.py b/awx/api/serializers.py index c832d598d4..6a34747518 100644 --- a/awx/api/serializers.py +++ b/awx/api/serializers.py @@ -5612,6 +5612,7 @@ class InstanceSerializer(BaseSerializer): # delete the receptor address if the port is None instance.receptor_addresses.filter(address=instance.hostname).delete() elif kwargs: + kwargs['canonical'] = True instance.receptor_addresses.update_or_create(address=instance.hostname, defaults=kwargs) return instance diff --git a/awx/main/models/receptor_address.py b/awx/main/models/receptor_address.py index fea1619249..1fa66bd647 100644 --- a/awx/main/models/receptor_address.py +++ b/awx/main/models/receptor_address.py @@ -28,7 +28,7 @@ class ReceptorAddress(models.Model): help_text=_("Protocol to use for the Receptor listener, 'tcp', 'wss', or 'ws'."), max_length=10, default=Protocols.TCP, choices=Protocols.choices ) is_internal = models.BooleanField(help_text=_("If True, only routable within the Kubernetes cluster."), default=False) - canonical = models.BooleanField(help_text=_("If True, this address is the canonical address for the instance."), default=True) + canonical = models.BooleanField(help_text=_("If True, this address is the canonical address for the instance."), default=False) peers_from_control_nodes = models.BooleanField(help_text=_("If True, control plane cluster nodes should automatically peer to it."), default=False) instance = models.ForeignKey( 'Instance',