postgrest-docs
postgrest-docs copied to clipboard
A second PostgREST-and-data instance, need for instructions in the Guide
The Guide says nothing about multiple databases (multiple instances of PostgREST). A typical implementation is one instance for production and another for testing.
PS: for some purposes, it is indifferent to use a second SQL scheme or a second SQL database, so in the same place in the Guide it is also necessary to say also (after new PostgREST version with issue PostgREST/postgrest#1106), that an alternative is to configure multiple schemas.
Environment
- PostgreSQL version: any
- PostgREST version: 6
- Operating system: Linux
Description of issue
Expected behavior: a Guide with explanations about multiple instances (each with different database) in the PostgREST/Docker implementation. Also, in the same place, about multiple schemas (when next PostgREST version ok).
Actual behavior: no clues, no instructions (!).
Steps to reproduce two-instances the configuration:
-
first docker at port 3000 using database testing0.
docker run -d --net=host -p 3000:3000 -e PGRST_DB_URI="postgres://postgres@localhost/testing0" -e PGRST_DB_ANON_ROLE="postgres" postgrest/postgrest
-
second docker at port 3002 using database production2
docker run --d --net=host -p 3002:3002 -e PGRST_SERVER_PORT="3002" -e PGRST_DB_URI="postgres://postgres@localhost/production2" -e PGRST_DB_ANON_ROLE="postgres" postgrest/postgrest
Note: the -p
seems reduntant (can be excluded?) with --net=host
.
Hi all, the issue was edited, now ok.
Documenting how to run multiple instances of PostgREST would come naturally with https://github.com/PostgREST/postgrest-docs/issues/69, so closing as duplicate.