Skip to content

Commit

Permalink
Fix uta container search path (#256)
Browse files Browse the repository at this point in the history
  • Loading branch information
b0d0nne11 authored Mar 26, 2024
1 parent ac8e34e commit feedaa6
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions misc/docker/load-uta.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

# Overwrite pg_hba.conf, including whatever edits might have been made
# by the postgres image
cat <<EOF >"$PGDATA/pg_hba.conf"
cat <<EOF >"$PGDATA/pg_hba.conf"
# allow the anonymous user to access uta without password
# These lines must occur before more stringent authentication methods
host all anonymous 0.0.0.0/0 trust
Expand Down Expand Up @@ -50,24 +50,24 @@ gzip -cdq < "${UTA_PGD_FN}" \

gzip -cdq < "${UTA_PGD_FN}" \
| perl -n \
-e 'm/CREATE SCHEMA (uta_\d+)/ && print("ALTER DATABASE :DBNAME SET search_path=$1;\n");' \
-e 'm/CREATE SCHEMA (uta_[\d\w]+)/ && print("ALTER DATABASE :DBNAME SET search_path=$1;\n");' \
-e 'print if s/CREATE MATERIALIZED VIEW (.\S+) AS/REFRESH MATERIALIZED VIEW $1;/' \
| psql -1e -U uta_admin -d uta -v ON_ERROR_STOP=1


cat <<EOF
=======================================================================
=======================================================================
==
==
== $UTA_VERSION installed from
== $UTA_PGD_URL
==
==
== You may now connect to uta like this:
==
==
== $ psql -h localhost -p <port> -U anonymous -d uta
==
==
== No password is required.
==
==
=======================================================================
=======================================================================
Expand Down

0 comments on commit feedaa6

Please sign in to comment.