r-scheele / rego_builder

Write your rego authorization rules from the frontend - Open policy agent
1 stars 1 forks source link

Integrate datasource #26

Closed r-scheele closed 2 years ago

r-scheele commented 2 years ago

The datasource database[Postgres] needs to be created before the application starts. i called it datasource.

  $ psql -U postgres
  postgres=# CREATE DATABASE datasource
    WITH
    OWNER = postgres
    ENCODING = 'UTF8'
    LC_COLLATE = 'C'
    LC_CTYPE = 'C'
    TABLESPACE = pg_default
    CONNECTION LIMIT = -1;

The /data/ route requires two sql script, to function:

  1. To create the tables, and fill it up.
  2. Retrieve data from this database - i suppose this would be supplied by our users or?

sample response:


{ 
  "users": [
       {....},
   ]
}
``
Youngestdev commented 2 years ago

Merging this to dev so I can test the changes. Changes will be merged to main once the deployment using Docker has been fixed.