Skip to content

Commit

Permalink
foreman/start-hydra: enable query log in postgres
Browse files Browse the repository at this point in the history
That way it's possible to observe which queries are fired against the DB
from DBIx. This is particularly useful to find out if DBIx correctly
prefetches everything it needs or if too much / too few things are
loaded, see e.g. NixOS#1335.
  • Loading branch information
Ma27 committed Mar 16, 2024
1 parent 8f56209 commit 1869339
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions foreman/start-hydra.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ createdb -h $(pwd)/.hydra-data/postgres -p 64444 hydra
# FATAL: database "USERNAME" does not exist
createdb -h $(pwd)/.hydra-data/postgres -p 64444 "$(whoami)" || true

psql -h localhost -p 64444 <<<"alter system set log_statement='all'; select pg_reload_conf();"

hydra-init
hydra-create-user alice --password foobar --role admin

Expand Down

0 comments on commit 1869339

Please sign in to comment.