summaryrefslogtreecommitdiffstats
path: root/ogcp/og_server.py
diff options
context:
space:
mode:
authorDaniel García Moreno <danigm@soleta.eu>2022-09-14 14:01:18 +0200
committerJavier Sánchez Parra <jsanchez@soleta.eu>2022-09-27 09:48:36 +0200
commit0c66443db89fec72c5fb2af0588a02695683613c (patch)
treebfdf3da7d960b1a17943e689d5b92c0f1b72337b /ogcp/og_server.py
parentea182079989407e382917d95cc86c77dbee7bff8 (diff)
Add multiple servers to the dashboard view
Diffstat (limited to 'ogcp/og_server.py')
-rw-r--r--ogcp/og_server.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/ogcp/og_server.py b/ogcp/og_server.py
index 0f542ff..38d9a01 100644
--- a/ogcp/og_server.py
+++ b/ogcp/og_server.py
@@ -37,6 +37,11 @@ class OGServer:
json=payload)
return r
+ @property
+ def id(self):
+ ip = self.ip.replace('.', '-')
+ return f'server_{ip}_{self.port}'
+
servers = []
if {'IP', 'PORT', 'API_TOKEN'} <= app.config.keys():