Closed Kerruba closed 1 week ago
Another issue I'm facing is the default anonymous user. From the README (and dockerhub page), seems like anon
is by default setup as the anonymous user, but if not configured manually with the correct env-variable is not able to access the apis, even if the user is correctly setup in the database
- name: PGRST_DB_ANON_ROLE
value: "anon"
Hi!
In the case of postgrest, we are not adding any container logic, so it is just the plain binary. In this sense, these issues you are experimenting are of the application itself, so my advice is to check with the upstream devs.
Hi @javsalgar, thanks for your reply.
The confusion is coming from the documentation on the bitnami docker image.
In the configuration section are mentioned many env-variables and their default value, but I couldn´t find any reference on the PostgREST website in configuration documentation.
Specifically, the DB_*
with their defaults are not mentioned anywhere.
There's though a reference to LIBPQ env variables .
Also some defaults are not what described in the PostgREST documentation, e.g. the PGRST_DB_ANON_ROLE
env-variable: https://postgrest.org/en/stable/references/configuration.html#db-anon-role)
Maybe is just a matter of updating the README to point to POSTGREST documentation?
Hi!
I understand the confusion. These env variables are used in the VM of Supabase, but not in the container or helm chart, so it safe to ignore them and just check the variables in the upstream documentation. I will let the team know that we should update the README.md (the env var section is auto-generated)
Ok thank you very much for the clarification. I'll leave the issue open, feel free to close it when appropriate :+1:
Name and Version
bitnami/potgrest:latest (11.2.2)
What architecture are you using?
amd64
What steps will reproduce the bug?
Postgres is up and running and exposed via a service in the same namespace as PostgREST, and I'm able to access it with regular psql within k8s and also from my local machine by portforwarding the port 5432.
When the Pod starts, it tells me is not able to connect to the database:
I attached it to the container and I couldn't find a configuration file for PostgREST, so I created one using the example configuration found on their site and started postgrest with that configuration, and it worked.
Checking the README, I've tried to manually add the
PGRST_DB_URI
env variable to the deploymentThe container is now starting correctly and the application can connect to the database.
What is the expected behavior?
By using the env variables listed in the README.md as customizable I would be able to connect to the database correctly
What do you see instead?
I get the connection error
and the only way of fixing this is by using the
PGRST_DB_URI
which I thought was read-only and not supposed to be changed