summary refs log tree commit diff
path: root/contrib/docker/start.py
diff options
context:
space:
mode:
authorkaiyou <pierre@jaury.eu>2018-02-05 23:13:27 +0100
committerkaiyou <pierre@jaury.eu>2018-02-05 23:13:27 +0100
commit1ffd9cb93617fe9bb2367d575786c0ff222cd415 (patch)
tree2eca3113f264d71c0849741d29a1beb70e1cbd0f /contrib/docker/start.py
parentAdd the non-tls port to the expose list (diff)
downloadsynapse-1ffd9cb93617fe9bb2367d575786c0ff222cd415.tar.xz
Support loading application service files from /data/appservices/
Diffstat (limited to '')
-rwxr-xr-xcontrib/docker/start.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/contrib/docker/start.py b/contrib/docker/start.py
index d3364e4226..8ade0f227d 100755
--- a/contrib/docker/start.py
+++ b/contrib/docker/start.py
@@ -4,6 +4,7 @@ import jinja2
 import os
 import sys
 import subprocess
+import glob
 
 convert = lambda src, dst, environ: open(dst, "w").write(jinja2.Template(open(src).read()).render(**environ))
 mode = sys.argv[1] if len(sys.argv) > 1 else None
@@ -26,6 +27,9 @@ for secret in ("SYNAPSE_REGISTRATION_SHARED_SECRET", "SYNAPSE_MACAROON_SECRET_KE
         print("Generating a random secret for {}".format(secret))
         environ[secret] = os.urandom(32).encode("hex")
 
+# Load appservices configurations
+environ["SYNAPSE_APPSERVICES"] = glob.glob("/data/appservices/*.yaml")
+
 # In generate mode, generate a configuration, missing keys, then exit
 if mode == "generate":
     os.execv("/usr/local/bin/python", args + ["--generate-config"])