diff --git a/deploy/docker/base.dockerfile b/deploy/docker/base.dockerfile index d6907208ad..6ce8453cc8 100644 --- a/deploy/docker/base.dockerfile +++ b/deploy/docker/base.dockerfile @@ -32,6 +32,8 @@ RUN set -o xtrace \ && ln -s /usr/lib/postgresql/13 /usr/lib/postgresql/current \ && apt-get clean +ENV PATH="/usr/lib/postgresql/13/bin:${PATH}" + # Install Java RUN set -o xtrace \ && mkdir -p /opt/java \ diff --git a/deploy/docker/fs/opt/appsmith/entrypoint.sh b/deploy/docker/fs/opt/appsmith/entrypoint.sh index 5add1b8e28..c35eefe857 100644 --- a/deploy/docker/fs/opt/appsmith/entrypoint.sh +++ b/deploy/docker/fs/opt/appsmith/entrypoint.sh @@ -4,6 +4,9 @@ set -e tlog "Running as: $(id)" +# Temporary, remove after this change goes into `base.dockerfile`. +export PATH="/usr/lib/postgresql/13/bin:${PATH}" + stacks_path=/appsmith-stacks export SUPERVISORD_CONF_TARGET="$TMP/supervisor-conf.d/" # export for use in supervisord.conf @@ -427,7 +430,7 @@ init_postgres() { if [[ ! -e "$POSTGRES_DB_PATH/PG_VERSION" ]]; then tlog "Initializing local Postgres data folder" - su postgres -c "/usr/lib/postgresql/13/bin/initdb -D $POSTGRES_DB_PATH" + su postgres -c "initdb -D $POSTGRES_DB_PATH" fi else runEmbeddedPostgres=0 diff --git a/deploy/docker/fs/opt/appsmith/run-postgres.sh b/deploy/docker/fs/opt/appsmith/run-postgres.sh index 427fa4a677..4f0b72b394 100755 --- a/deploy/docker/fs/opt/appsmith/run-postgres.sh +++ b/deploy/docker/fs/opt/appsmith/run-postgres.sh @@ -1,4 +1,4 @@ #!/bin/bash rm -f /appsmith-stacks/data/postgres/main/core.* -exec /usr/lib/postgresql/13/bin/postgres -D "/appsmith-stacks/data/postgres/main" -c listen_addresses=127.0.0.1 +exec postgres -D "/appsmith-stacks/data/postgres/main" -c listen_addresses=127.0.0.1