summaryrefslogtreecommitdiffstats
path: root/ogcp/views.py
diff options
context:
space:
mode:
authorJavier Sánchez Parra <jsanchez@soleta.eu>2022-10-26 17:48:34 +0200
committerJavier Sánchez Parra <jsanchez@soleta.eu>2022-11-07 12:58:27 +0100
commit0f6641d92f40da61c83d518b7c9c54a53daa6943 (patch)
tree8ad6c1687d41e6334dae8cd6fb1e5c508aa8d2b1 /ogcp/views.py
parentf834253a80a45d40052c3f6f19aed8ca9277f643 (diff)
Set server variable on GET /action/image/update
Otherwise, ogCP crashes on image update. Fixes: 8726ade ("Adapt commands to work with several ogServers")
Diffstat (limited to 'ogcp/views.py')
-rw-r--r--ogcp/views.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/ogcp/views.py b/ogcp/views.py
index 3243062..e0911b0 100644
--- a/ogcp/views.py
+++ b/ogcp/views.py
@@ -1189,6 +1189,7 @@ def action_image_update():
return redirect(url_for('commands'))
form.ip.data = ' '.join(ips)
+ server = get_server_from_clients(ips)
r = server.get('/images')
for image in r.json()['images']:
form.image.choices.append((image['id'], image['name']))