@@ -80,10 +80,23 @@ function enable_lsn_checkpoint_push {
80
80
}
81
81
82
82
function disable_fail2ban {
83
+ sed -i " s/command=.*/command=sleep 5/" /etc/supervisor/services/fail2ban.conf
83
84
sed -i " s/autostart=.*/autostart=false/" /etc/supervisor/services/fail2ban.conf
84
85
sed -i " s/autorestart=.*/autorestart=false/" /etc/supervisor/services/fail2ban.conf
85
86
}
86
87
88
+ function disable_gotrue {
89
+ sed -i " s/command=.*/command=sleep 5/" /etc/supervisor/services/gotrue.conf
90
+ sed -i " s/autostart=.*/autostart=false/" /etc/supervisor/services/gotrue.conf
91
+ sed -i " s/autorestart=.*/autorestart=false/" /etc/supervisor/services/gotrue.conf
92
+ }
93
+
94
+ function disable_pgbouncer {
95
+ sed -i " s/command=.*/command=sleep 5/" /etc/supervisor/services/pgbouncer.conf
96
+ sed -i " s/autostart=.*/autostart=false/" /etc/supervisor/services/pgbouncer.conf
97
+ sed -i " s/autorestart=.*/autorestart=false/" /etc/supervisor/services/pgbouncer.conf
98
+ }
99
+
87
100
function setup_postgres {
88
101
tar -xzvf " $INIT_PAYLOAD_PATH " -C / ./etc/postgresql.schema.sql
89
102
mv /etc/postgresql.schema.sql /docker-entrypoint-initdb.d/migrations/99-schema.sql
@@ -285,8 +298,11 @@ if [ "${FAIL2BAN_DISABLED:-}" == "true" ]; then
285
298
fi
286
299
287
300
if [ " ${GOTRUE_DISABLED:- } " == " true" ]; then
288
- sed -i " s/autostart=.*/autostart=false/" /etc/supervisor/services/gotrue.conf
289
- sed -i " s/autorestart=.*/autorestart=false/" /etc/supervisor/services/gotrue.conf
301
+ disable_gotrue
302
+ fi
303
+
304
+ if [ " ${PGBOUNCER_DISABLED:- } " == " true" ]; then
305
+ disable_pgbouncer
290
306
fi
291
307
292
308
if [ " ${PLATFORM_DEPLOYMENT:- } " == " true" ]; then
0 commit comments