mirror of
https://github.com/element-hq/synapse.git
synced 2024-11-21 09:05:42 +03:00
Prevent start_for_complement.sh
from setting START_POSTGRES
to false
when it's already set (#16985)
I have a use case where I'd like the Synapse image to start up a postgres instance that I can use, but don't want to force Synapse to use postgres as well. This commit prevents postgres from being started when it has already been explicitly enabled elsewhere.
This commit is contained in:
parent
cf5adc80e1
commit
21daa56ee1
3 changed files with 5 additions and 3 deletions
1
changelog.d/16985.misc
Normal file
1
changelog.d/16985.misc
Normal file
|
@ -0,0 +1 @@
|
|||
Allow containers building on top of Synapse's Complement container is use the included PostgreSQL cluster.
|
|
@ -1,7 +1,7 @@
|
|||
[program:postgres]
|
||||
command=/usr/local/bin/prefix-log gosu postgres postgres
|
||||
|
||||
# Only start if START_POSTGRES=1
|
||||
# Only start if START_POSTGRES=true
|
||||
autostart=%(ENV_START_POSTGRES)s
|
||||
|
||||
# Lower priority number = starts first
|
||||
|
|
|
@ -32,8 +32,9 @@ case "$SYNAPSE_COMPLEMENT_DATABASE" in
|
|||
;;
|
||||
|
||||
sqlite|"")
|
||||
# Configure supervisord not to start Postgres, as we don't need it
|
||||
export START_POSTGRES=false
|
||||
# Set START_POSTGRES to false unless it has already been set
|
||||
# (i.e. by another container image inheriting our own).
|
||||
export START_POSTGRES=${START_POSTGRES:-false}
|
||||
;;
|
||||
|
||||
*)
|
||||
|
|
Loading…
Reference in a new issue