Skip to content

Commit 60a249d

Browse files
author
Sameer Naik
committed
ensure required defaults are set at every start
1 parent 490f33c commit 60a249d

1 file changed

Lines changed: 13 additions & 13 deletions

File tree

runtime/functions

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -224,26 +224,26 @@ initialize_database() {
224224
;;
225225
esac
226226

227-
# configure path to data_directory
228-
set_postgresql_param "data_directory" "${PG_DATADIR}"
229-
230-
# configure logging
231-
set_postgresql_param "log_directory" "${PG_LOGDIR}"
232-
set_postgresql_param "log_filename" "postgresql-${PG_VERSION}-main.log"
233-
234-
# listen on all interfaces
235-
set_postgresql_param "listen_addresses" "*"
236-
237-
# allow remote connections to postgresql database
238-
set_hba_param "host all all 0.0.0.0/0 md5"
239-
240227
configure_hot_standby
241228

242229
# Change DSM from `posix' to `sysv' if we are inside an lx-brand container
243230
if [[ $(uname -v) == "BrandZ virtual linux" ]]; then
244231
set_postgresql_param "dynamic_shared_memory_type" "sysv"
245232
fi
246233
fi
234+
235+
# configure path to data_directory
236+
set_postgresql_param "data_directory" "${PG_DATADIR}"
237+
238+
# configure logging
239+
set_postgresql_param "log_directory" "${PG_LOGDIR}"
240+
set_postgresql_param "log_filename" "postgresql-${PG_VERSION}-main.log"
241+
242+
# listen on all interfaces
243+
set_postgresql_param "listen_addresses" "*"
244+
245+
# allow remote connections to postgresql database
246+
set_hba_param "host all all 0.0.0.0/0 md5"
247247
}
248248

249249
trust_localnet() {

0 commit comments

Comments
 (0)