mirror of
https://git.anonymousland.org/anonymousland/synapse-product.git
synced 2024-12-31 21:26:13 -05:00
Docker: Change permissions for data dir before attempting to write to it (#6389)
This commit is contained in:
parent
4f5ca455bf
commit
234f55f3c4
1
changelog.d/6389.bugfix
Normal file
1
changelog.d/6389.bugfix
Normal file
@ -0,0 +1 @@
|
||||
Fix permission denied error when trying to generate a config file with the docker image.
|
@ -169,11 +169,11 @@ def run_generate_config(environ, ownership):
|
||||
# log("running %s" % (args, ))
|
||||
|
||||
if ownership is not None:
|
||||
args = ["su-exec", ownership] + args
|
||||
os.execv("/sbin/su-exec", args)
|
||||
|
||||
# make sure that synapse has perms to write to the data dir.
|
||||
subprocess.check_output(["chown", ownership, data_dir])
|
||||
|
||||
args = ["su-exec", ownership] + args
|
||||
os.execv("/sbin/su-exec", args)
|
||||
else:
|
||||
os.execv("/usr/local/bin/python", args)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user