Members of pipelines and commissioning teams may need direct access to the APDB in the USDF; this page describes how to configure such authorization.

As of this writing (September 2023), precursor processing uses two postgres APDB instances:

Obtain Production APDB Credentials

Go to (select "oidc" and then use your SLAC UNIX credentials.  If you get "permission denied" you will need to request support on #ops-usdf).

Obtain dev APDB Credentials

Precursor processing presently uses the -dev database.  Obtain the secrets at

Update $HOME/.lsst/postgres-credentials.txt

For each database, add a line to $HOME/.lsst/postgres-credentials.txt that is


where the values of url, database, username, and password are given from those field names in the Vault entry.  Note that the vault entry "url" is of the format hostname:port  ( and database is lsst-devl 

For weeklies starting with w_2023_14 this value won't be overwritten by future RSP deployments.

You can test that your credentials work as expected on the production database by executing

psql -h lsst-devl rubin -c 'set search_path to pp_apdb; select count(*) from "DiaObject";'

You can list the schema names for precursor processing by executing

psql -h lsst-devl rubin -c '\dn;'


At present (Sept. 2023) all database access is using the shared "rubin" user.  Be careful when executing commands which might delete data!

  • No labels