BREAKING CHANGE: don't set connection env vars #13
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The 'setup-postgres' action used to set libpq environment variables [1] with connection parameters so the PostgreSQL client applications [2], such as 'psql' or 'createuser', won't require any configuration before using.
Unfortunately these libpq environment variables are also used by all libpq clients including database drivers such as 'psycopg'. While this may sound good, it may as well lead to undesired behaviour and unobvious issues when connection parameters are automatically pulled from environment but most not.
Nevertheless, the need to easy usage of the client applications [2] is indisputable because providing a bunch of connection parameters all the time is tedious. Therefore this patch pushes requires connection parameters to the connection service file [3], so the client applications can pull the data on-demand. E.g:
[1] https://www.postgresql.org/docs/15/libpq-envars.html
[2] https://www.postgresql.org/docs/15/reference-client.html
[3] https://www.postgresql.org/docs/15/libpq-pgservice.html