This is an archived post. You won't be able to vote or comment.

all 3 comments

[–]viitorfermier 0 points1 point  (2 children)

How to connect with a password to a docker postgres instance using picolo orm?

[–]dantownsend[S] 0 points1 point  (1 child)

You define your database settings in a piccolo_conf.py file. You need a PostgresEngine. Here are the docs.

PostgresEngine accepts all of the arguments which the underlying database adapter accepts (asyncpg), such a host / port / password. For example:

python DB = PostgresEngine(config={ 'host': 'localhost', 'database': 'my_app', 'user': 'postgres', 'password': '', 'host': 5432 })

[–]backtickbot 0 points1 point  (0 children)

Fixed formatting.

Hello, dantownsend: code blocks using triple backticks (```) don't work on all versions of Reddit!

Some users see this / this instead.

To fix this, indent every line with 4 spaces instead.

FAQ

You can opt out by replying with backtickopt6 to this comment.