Skip to content

Commit 6690fd0

Browse files
committed
Install pg_search extension
1 parent 18cb63b commit 6690fd0

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

Dockerfile

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ ARG PG_MAJOR=15
44
FROM postgres:${PG_MAJOR}
55

66
ARG POSTGIS_VERSION=3
7+
ARG PG_SEARCH_VERSION=0.15.25
78
ENV PGDATA=/var/lib/postgresql/docker
89
ENV POSTGRES_PASSWORD=
910

@@ -19,6 +20,14 @@ RUN \
1920
apt-get clean && \
2021
rm -rf /var/lib/apt/lists/*
2122

23+
# Install pg_search extension
24+
RUN \
25+
curl -o pg-search.deb -L https://github.com/paradedb/paradedb/releases/download/v${PG_SEARCH_VERSION}/postgresql-${PG_MAJOR}-pg-search_${PG_SEARCH_VERSION}-1PARADEDB-bookworm_amd64.deb && \
26+
dpkg -i pg-search.deb && \
27+
echo "shared_preload_libraries='pg_search'" >> /usr/share/postgresql/postgresql.conf.sample && \
28+
rm pg-search.deb
29+
30+
2231
# Setup database
2332
# script to create DB, roles, grants etc
2433
COPY setup-roles-and-db.sh /docker-entrypoint-initdb.d/0_setup-db.sh

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ These images are designed to be configured in a `docker-compose.yml` as follows
3131
Note:
3232
3333
* **You need to set a non-empty `POSTGRES_PASSWORD` ENV variable**.
34-
* You can set passwords for roles in `qwc_services` database with ENV variables: `QGIS_SERVER_PASSWORD`, `QWC_ADMIN_PASSWORD`, `QWC_SERVICE_PASSWORD`, `QWC_SERVICE_WRITE_PASSWORD`. These variables have default values (`qgis_server`, `qwc_admin`, `qwc_service`, `qwc_service_write`).
34+
* You can set passwords for roles in `qwc_services` database with ENV variables: `QWC_ADMIN_PASSWORD`, `QWC_SERVICE_PASSWORD`, `QWC_SERVICE_WRITE_PASSWORD`. These variables have default values (`qgis_server`, `qwc_admin`, `qwc_service`, `qwc_service_write`).
3535
* For persistent storage, mount folder volume to `/var/lib/postgresql/docker`.
3636
* The `sourcepole/qwc-base-db` images are versioned according to the Postgres major version (i.e. 13, 14, 15, ...).
3737
* The `sourcepole/qwc-base-db-migrate` images are versioned by date (`vYYYY.MM.DD`)
@@ -65,7 +65,7 @@ By default, the DB specified by the `qwc_configdb` connection will be upgraded.
6565

6666
You can use an external DB instead of the `qwc-base-db` dockerized DB.
6767

68-
To set up the external DB, set passwords for roles with ENV variables (`QGIS_SERVER_PASSWORD`, `QWC_ADMIN_PASSWORD`, `QWC_SERVICE_PASSWORD`, `QWC_SERVICE_WRITE_PASSWORD`) and run the SQL commands in `setup-roles-and-db.sh` on your external DB.
68+
To set up the external DB, set passwords for roles with ENV variables (`QWC_ADMIN_PASSWORD`, `QWC_SERVICE_PASSWORD`, `QWC_SERVICE_WRITE_PASSWORD`) and run the SQL commands in `setup-roles-and-db.sh` on your external DB.
6969

7070
To apply the migrations, both as part as the initial setup and subsequently to keep the Config DB up-to-date:
7171

0 commit comments

Comments
 (0)