Skip to content

Commit

Permalink
Update install instructions in readme
Browse files Browse the repository at this point in the history
  • Loading branch information
Yrob committed Aug 1, 2024
1 parent 9bde128 commit 042fccb
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,45 @@ Part of that means that the API follows the HAL-JSON style.

# Installation

## Using Docker Compose (recommended for development)

Run docker compose:
```
docker compose up
```

Navigate to `localhost:8090`.

By default a collection of example datasets is loaded, and a local database is setup and initialized.
This behaviour can be changed with environment variables as described below.

### Environment

The following environment variables are useful for configuring a local development environment.

* `DATABASE_URL`: the postgresql URL of the database the application should connect to.
The default is the `database` container in the compose file.
* `INITIALIZE_DB`: Initialize the database with django migrate and import schema's. Default `true`.
* `MOCK_DATA`: Fill the initialized database with autogenerated mock data. Default: `false`.
* `SCHEMA_URL`: URL of the dataset schemas. To use the production schemas set this to:
"https://schemas.data.amsterdam.nl/datasets/"
Default is the `schemas` container in the compose file.

To connect to an authentication provider, setup the following environment variables:
* `OAUTH_CLIENT_ID`: The client id of the application
* `OAUTH_JWKS_URL`: The JWKS URL of the authentication provider.
* `OAUTH_URL`: The auth URL of the authentication provider.

#### Example
A local setup using the production dataset schema's with mock data:
```
export INITIALIZE_DB=true
export MOCK_DATA=true
export SCHEMA_URL="https://schemas.data.amsterdam.nl/datasets/"
compose up
```

## Without Docker Compose
See the instructions at: <https://dso-api.readthedocs.io/en/latest/howto/install.html>

These instructions can also be found in the ``dev-docs/source/howto/install.rst`` file.
Expand Down

0 comments on commit 042fccb

Please sign in to comment.