adonisjs / lucid

AdonisJS SQL ORM. Supports PostgreSQL, MySQL, MSSQL, Redshift, SQLite and many more
https://lucid.adonisjs.com/
MIT License
1.07k stars 191 forks source link

feat(config): add connectionString option to PostgresConnectionNode type #972

Closed loadnull closed 5 months ago

loadnull commented 10 months ago

Proposed changes

Add the connectionString option to the Postgres connection config.

See: https://node-postgres.com/features/connecting#connection-uri

Types of changes

What types of changes does your code introduce?

Put an x in the boxes that apply

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

Further comments

Using the connection.connectionString option instead of just setting connection to the Postgres URI allows you to also set the connection.ssl options.

thetutlage commented 10 months ago

The types are broken after the change, can you please look into it?

loadnull commented 10 months ago

Just tried npx tsc on a fresh clone of the develop branch and it fails with the same error so it's not specific to this PR.

Not sure how to resolve.

stale[bot] commented 6 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.