From c538bd17f808f7da3db919b2f89c1be992b72eaa Mon Sep 17 00:00:00 2001 From: Xavier-Do Date: Mon, 1 Mar 2021 15:49:23 +0100 Subject: [PATCH] [IMP] runbot: use build database_ids to generate connect links aka: make it clean This build database_ids field was generated a few months, waiting for the database to update with this new sceme before using it. It is still a little early to use it in cleanup methods, but this can be used to generate the connect links dynamicaly. To follow al specs introduced in previous commit, main fa-sign-in button should link to the -all. It will almost always be the first one in database_ids in alphabetic order. Then, in the dropdown, all other database are listed. This will fix the previously broken design_theme connect link (no base nor all). For this purpose nginx regex needs to be adapted to accept database name with underscore. --- runbot/templates/nginx.xml | 2 +- runbot/templates/utils.xml | 18 ++++++++++-------- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/runbot/templates/nginx.xml b/runbot/templates/nginx.xml index a8f39567..1e32e38b 100644 --- a/runbot/templates/nginx.xml +++ b/runbot/templates/nginx.xml @@ -54,7 +54,7 @@ server { server { listen 8080; - server_name ~^(-[a-z0-9]+)?\.$; + server_name ~^(-[a-z0-9_]+)?\.$; location / { proxy_pass http://127.0.0.1:; } location /longpolling { proxy_pass http://127.0.0.1:; } } diff --git a/runbot/templates/utils.xml b/runbot/templates/utils.xml index 0a3d62d3..b427e81e 100644 --- a/runbot/templates/utils.xml +++ b/runbot/templates/utils.xml @@ -164,7 +164,7 @@ - @@ -175,7 +175,7 @@