mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
[fix] Do not load conf.json before overriding content.
This commit is contained in:
parent
e32ea4180a
commit
b0735af6ce
1 changed files with 2 additions and 5 deletions
7
app.py
7
app.py
|
@ -924,10 +924,7 @@ def app_ssowatconf(auth):
|
||||||
for domain in domains:
|
for domain in domains:
|
||||||
skipped_urls.extend(['/yunohost/admin', '/yunohost/api'])
|
skipped_urls.extend(['/yunohost/admin', '/yunohost/api'])
|
||||||
|
|
||||||
with open('/etc/ssowat/conf.json') as f:
|
conf_dict = {
|
||||||
conf_dict = json.load(f)
|
|
||||||
|
|
||||||
conf_dict.update({
|
|
||||||
'portal_domain': main_domain,
|
'portal_domain': main_domain,
|
||||||
'portal_path': '/yunohost/sso/',
|
'portal_path': '/yunohost/sso/',
|
||||||
'additional_headers': {
|
'additional_headers': {
|
||||||
|
@ -945,7 +942,7 @@ def app_ssowatconf(auth):
|
||||||
'protected_regex': protected_regex,
|
'protected_regex': protected_regex,
|
||||||
'redirected_regex': redirected_regex,
|
'redirected_regex': redirected_regex,
|
||||||
'users': users,
|
'users': users,
|
||||||
})
|
}
|
||||||
|
|
||||||
with open('/etc/ssowat/conf.json', 'w+') as f:
|
with open('/etc/ssowat/conf.json', 'w+') as f:
|
||||||
json.dump(conf_dict, f, sort_keys=True, indent=4)
|
json.dump(conf_dict, f, sort_keys=True, indent=4)
|
||||||
|
|
Loading…
Add table
Reference in a new issue