Skip to content

Commit e510e12

Browse files
committed
fix: start-server macos
1 parent 9abe2c9 commit e510e12

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

nix/tools/run-server.sh.in

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ session_preload_libraries = 'supautils'" \
6565
"$PSQL_CONF_FILE" > "$DATDIR/postgresql.conf"
6666

6767
orioledb_config_items() {
68-
if [ "$1" == "orioledb-17" ]; then
68+
if [[ "$1" = "orioledb-17" && "$CURRENT_SYSTEM" != "aarch64-darwin" ]]; then
6969
# Remove items from postgresql.conf
7070
sed -i 's/ timescaledb,//g;' "$DATDIR/postgresql.conf"
7171
#as of pg 16.4 + this db_user_namespace totally deprecated and will break the server if setting is present
@@ -75,6 +75,16 @@ orioledb_config_items() {
7575
echo "default_table_access_method = 'orioledb'" >> "$DATADIR/postgresql.conf"
7676

7777
fi
78+
if [[ "$1" = "orioledb-17" && "$CURRENT_SYSTEM" = "aarch64-darwin" ]]; then
79+
# Remove items from postgresql.conf
80+
sed -i '' 's/ timescaledb,//g;' "$DATDIR/postgresql.conf"
81+
#as of pg 16.4 + this db_user_namespace totally deprecated and will break the server if setting is present
82+
sed -i '' 's/db_user_namespace = off/#db_user_namespace = off/g;' "$DATDIR/postgresql.conf"
83+
sed -i '' 's/ timescaledb,//g; s/ plv8,//g; s/ postgis,//g; s/ pgrouting,//g' "$DATDIR/supautils.conf"
84+
sed -i '' 's/\(shared_preload_libraries.*\)'\''\(.*\)$/\1, orioledb'\''\2/' "$DATADIR/postgresql.conf"
85+
echo "default_table_access_method = 'orioledb'" >> "$DATADIR/postgresql.conf"
86+
87+
fi
7888
}
7989
orioledb_config_items "$1"
8090
if [ "$CURRENT_SYSTEM" = "aarch64-darwin" ]; then

0 commit comments

Comments
 (0)