Are you interested in making things better? Then by all means contribute! You can do so in a number of ways:
- Contact GSA about regulations.gov and relate your own experience (good or bad) to the new regulations.gov site
- Submit a feature request or a bug report on this site using GitHub Issues.
- Create your own application on top of the regulations.gov API so we can show them what can be done.
- Or you could contribute code to this application! Information on how to run this app locally and submit a PR are located below.
flowchart LR
APP["Node App"]
DM["Docket Model"]
UM["User Model"]
R["Redis Cache"]
PG["Postgres DB"]
API["Regulations.gov API"]
subgraph UI Layer
Views -- Incorporates --> Partials
Views -- Loads --> Styles
Views -- Loads --> JavaScript
end
subgraph Node Server
APP -- implements --> Routes
Routes -- calls --> UM
Routes -- calls --> DM
end
subgraph Data Layer
UM -- reads/writes --> PG
APP -- stores user sessions --> R
DM -- caches API data --> R
end
JavaScript -- sends requests --> APP
DM -- calls --> API
This system can be run almost entirely locally. The only piece that can't be run locally is the regulations.gov API. But you can easily sign up for an API key yourself in order to hit the API. You could also create a mock API for development if you like.
- Create an SSL certificate for
localhost
since Chrome/Firefox force you there. Put the decrypted key and crt in alocalcert
directory inside this project. - Install Node.js (check the
package.json
file to see what version the site runs on) - Install and run Postgres
- Create a Postgres user and database, then create the
user
table using theschema/user.sql
file to create the table(s) - Install and run Redis for session and document caching
- Install the dependencies with
npm install
- Configure your environment variables by copying
.env.example
and renaming it to.env
, then change the values to match your local environment!
Now you should be ready to run the application locally with node .
(or use npm run watch
to continuously watch for file changes and restart the app).
Please be sure to follow the Pull Request template on GitHub. This ensures that the changes can be reviewed thoroughly and integrated!