Skip to content

Platform independent install instructions

Christopher Keith edited this page Mar 5, 2023 · 17 revisions

Clone repository:

  • cd <directory for your repository> e.g., cd ~/github
  • git clone https://github.com/usdigitalresponse/usdr-gost.git

Set up app password for sending emails as described in https://github.com/usdigitalresponse/usdr-gost/tree/_staging

Set up .env files:

  • cd usdr-gost/
  • cp packages/server/.env.example packages/server/.env
  • cp packages/client/.env.example packages/client/.env

Edit .env file(s) as described in the Docker README.md, e.g.:

  • Remove any comment lines (starting with #)
  • Set NODEMAILER* variables in server/.env, e.g.,

Follow instructions in the Docker README.md in the Setup and Seed sections

  • After docker compose up -d ...
  • Run docker compose exec app yarn setup

Run test suites:

  • docker compose exec app yarn test

Add yourself as a user

  • Run bash in Docker container
    • docker compose exec postgres bash
    • export PGPASSWORD=<ask_someone_for_the_password>
    • psql -h postgres -p 5432 -d usdr_grants -U postgres
      • Substitute your email and name into this SQL command (inside the single quotes).
      • Paste it after the pqsl prompt.
      • insert into users (email, name, role_id, agency_id, tenant_id) values ('your.email.here', 'your name here', 1, 0, 1);
      • \q
    • exit

Verify that you can get to the login page and login

Setup nvm and yarn

Recommended but not required: