From d29af32779b4a78a9f5386e7c3ce95dde9ea1fc5 Mon Sep 17 00:00:00 2001 From: Alexandre <44178713+alexbelgium@users.noreply.github.com> Date: Wed, 31 Jan 2024 10:25:26 +0100 Subject: [PATCH] Update 99-run.sh --- postgres/rootfs/etc/cont-init.d/99-run.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/postgres/rootfs/etc/cont-init.d/99-run.sh b/postgres/rootfs/etc/cont-init.d/99-run.sh index 2c2237ab8..e27e7691e 100755 --- a/postgres/rootfs/etc/cont-init.d/99-run.sh +++ b/postgres/rootfs/etc/cont-init.d/99-run.sh @@ -36,8 +36,9 @@ chmod -R 777 "$CONFIG_HOME" # Set variables for vector.rs DB_PORT=5432 DB_HOSTNAME=localhost -DB_USERNAME=postgres DB_PASSWORD="$(bashio::config 'POSTGRES_PASSWORD')" +if bashio::config.has_value "POSTGRES_USER"; then POSTGRES_USER="$(bashio::config "POSTGRES_USER")"; else POSTGRES_USER=postgres; fi + export DB_PORT export DB_HOSTNAME export DB_USERNAME