Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added more info to config section of README.md #286

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 26 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ npm install

### Config

You must create `config.py` in the top-level directory with the appropriate credentials for the application to run. See `config.sample.py` for an example.
You must create `config.py` in the top-level directory with the appropriate credentials for the application to run. See `config.env.py` for an example.

#### Add OIDC Config
Reach out to an RTP to get OIDC credentials that will allow you to develop locally behind OIDC auth
Expand All @@ -47,6 +47,31 @@ OIDC_CLIENT_CONFIG = {
}
```

#### Gain EBoard Privileges Locally
In order to view pages that normally only eboard members can see it is reccomended that you do this these things:

* Set up a local database.

To do this through docker, run

```
docker run --name postgres --mount target=/var/lib/postgresql/data,type=volume,src=conditional-db -e POSTGRES_PASSWORD=mysecretpassword -d -p 5432:5432 postgres
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
docker run --name postgres --mount target=/var/lib/postgresql/data,type=volume,src=conditional-db -e POSTGRES_PASSWORD=mysecretpassword -d -p 5432:5432 postgres
docker run --name postgres -e POSTGRES_PASSWORD=mysecretpassword -d -p 5432:5432 postgres

You don't need to mount anything, the container db will persist as long as the container sticks around.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, you should change config.env.py to use the connection string for this as the default.

```

* Modify functions in `ldap.py`
```
@service_cache(maxsize=128)
def ldap_is_eboard(account):
return True
```

```
@service_cache(maxsize=128)
def ldap_is_eval_director(account):
return True
```
**Note: Do not commit these changes.**

### Run

Once you have all of the dependencies installed, simply run:
Expand Down