mirror of
https://github.com/ansible/awx.git
synced 2026-03-07 19:51:08 -03:30
Add validation when setting peers
- cannot peer to self - cannot peer to instance that is already peered to self Other changes: - ReceptorAddress protocol field restricted to choices: tcp, ws, wss - fix awx-manage list_instances when instance.last_seen is None - InstanceLink make source and target unique together - Add help text to the ReceptorAddress fields Signed-off-by: Seth Foster <fosterbseth@gmail.com>
This commit is contained in:
@@ -55,7 +55,7 @@ class Command(BaseCommand):
|
||||
|
||||
capacity = f' capacity={x.capacity}' if x.node_type != 'hop' else ''
|
||||
version = f" version={x.version or '?'}" if x.node_type != 'hop' else ''
|
||||
heartbeat = f' heartbeat="{x.last_seen:%Y-%m-%d %H:%M:%S}"' if x.last_seen and x.capacity or x.node_type == 'hop' else ''
|
||||
heartbeat = f' heartbeat="{x.last_seen:%Y-%m-%d %H:%M:%S}"' if x.last_seen else ''
|
||||
print(f'\t{color}{x.hostname}{capacity} node_type={x.node_type}{version}{heartbeat}{end_color}')
|
||||
|
||||
print()
|
||||
|
||||
Reference in New Issue
Block a user