HPC service fields for port80 and watcher networks
diff --git a/xos/hpc/admin.py b/xos/hpc/admin.py
index d171beb..9664d07 100644
--- a/xos/hpc/admin.py
+++ b/xos/hpc/admin.py
@@ -191,7 +191,7 @@
verbose_name_plural = "HPC Service"
list_display = ("backend_status_icon", "name","enabled")
list_display_links = ('backend_status_icon', 'name', )
- fieldsets = [(None, {'fields': ['backend_status_text', 'name','scale','enabled','versionNumber', 'description', "cmi_hostname"], 'classes':['suit-tab suit-tab-general']})]
+ fieldsets = [(None, {'fields': ['backend_status_text', 'name','scale','enabled','versionNumber', 'description', "cmi_hostname", "hpc_port80", "watcher_hpc_network", "watcher_dnsredir_network", "watcher_dnsdemux_network"], 'classes':['suit-tab suit-tab-general']})]
readonly_fields = ('backend_status_text', )
inlines = [SliceInline,ServiceAttrAsTabInline,ServicePrivilegeInline]
form = HpcServiceForm
diff --git a/xos/hpc/models.py b/xos/hpc/models.py
index 7ba0b34..c0f7ba9 100644
--- a/xos/hpc/models.py
+++ b/xos/hpc/models.py
@@ -17,6 +17,11 @@
cmi_hostname = StrippedCharField(max_length=254, null=True, blank=True)
+ hpc_port80 = models.BooleanField(default=True, help_text="Enable port 80 for HPC")
+ watcher_hpc_network = StrippedCharField(max_length=254, null=True, blank=True, help_text="Network for hpc_watcher to contact hpc sliver")
+ watcher_dnsdemux_network = StrippedCharField(max_length=254, null=True, blank=True, help_text="Network for hpc_watcher to contact dnsdemux sliver")
+ watcher_dnsredir_network = StrippedCharField(max_length=254, null=True, blank=True, help_text="Network for hpc_watcher to contact dnsredir sliver")
+
@property
def scale(self):
hpc_slices = [x for x in self.slices.all() if "hpc" in x.name]