mirror of
https://github.com/ansible/awx.git
synced 2026-07-10 15:58:05 -02:30
@@ -45,11 +45,6 @@ class Instance(BaseModel):
|
||||
|
||||
uuid = models.CharField(max_length=40)
|
||||
hostname = models.CharField(max_length=250, unique=True)
|
||||
system_hostname = models.CharField(
|
||||
max_length=255,
|
||||
db_index=True,
|
||||
help_text="Machine hostname",
|
||||
)
|
||||
created = models.DateTimeField(auto_now_add=True)
|
||||
modified = models.DateTimeField(auto_now=True)
|
||||
last_isolated_check = models.DateTimeField(
|
||||
@@ -114,10 +109,6 @@ class Instance(BaseModel):
|
||||
def jobs_total(self):
|
||||
return UnifiedJob.objects.filter(execution_node=self.hostname).count()
|
||||
|
||||
@property
|
||||
def celery_system_hostname(self):
|
||||
return 'celery@{}'.format(self.system_hostname)
|
||||
|
||||
def is_lost(self, ref_time=None, isolated=False):
|
||||
if ref_time is None:
|
||||
ref_time = now()
|
||||
|
||||
Reference in New Issue
Block a user