ui - fix example, subpath behind reverse proxy and add socket proxy rights for swarm

This commit is contained in:
florian
2021-08-07 21:56:08 +02:00
parent 0c1883472d
commit dd7d1a2c78
6 changed files with 147 additions and 126 deletions

View File

@@ -47,17 +47,16 @@ class Instances :
# Docker instances (containers or services)
if self.__docker != None :
if self.__docker.swarm == None :
for instance in self.__docker.containers.list(all=True, filters={"label" : "bunkerized-nginx.UI"}) :
id = instance.id
name = instance.name
type = "container"
status = "down"
if instance.status == "running" :
status = "up"
instances.append(self.__instance(id, name, type, status, instance))
else :
for instance in self.__docker.services.list(all=True, filters={"label" : "bunkerized-nginx.UI"}) :
for instance in self.__docker.containers.list(all=True, filters={"label" : "bunkerized-nginx.UI"}) :
id = instance.id
name = instance.name
type = "container"
status = "down"
if instance.status == "running" :
status = "up"
instances.append(self.__instance(id, name, type, status, instance))
if self.__docker.swarm != None :
for instance in self.__docker.services.list(filters={"label" : "bunkerized-nginx.UI"}) :
id = instance.id
name = instance.name
type = "service"