Skip to content

Commit

Permalink
Merge pull request #239 from kbss-cvut/add-documentation-to-develop-b…
Browse files Browse the repository at this point in the history
…ackend

Add documentation how to develop backend using docker services
  • Loading branch information
blcham authored Nov 13, 2024
2 parents f4884a3 + ac4f7c2 commit 30757d3
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions doc/development.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,19 @@ To configure the application use [Setup Guide](./setup.md).
To run the application in development mode use `npm run dev`.
By default, the application is accessible from http://localhost:5173.

### Running with Dockerized Services and Internal Authorization
### Development with Dockerized Services

It is possible to develop the frontend over prepared docker services.

#### Using Internal Authorization

This section describes the development scenario when developer uses
[dockerized services with internal authorization](../deploy/internal-auth/docker-compose.yml) to develop.
All the services, including dockerized record-manager-ui, run by default at URL starting with `http://localhost:1235/record-manager`.
To attach simultaneously frontend for the development use setup from [.env.internal-auth](../.env.internal-auth),
e.g., by running `ln -s .env.internal-auth .env; npm run dev`.

### Running with Dockerized Services and Keycloak Authorization
#### Using Keycloak Authorization

This section describes the development scenario when developer uses
[dockerized services with keycloak authorization](../deploy/keycloak-auth/docker-compose.yml) to develop.
Expand All @@ -27,6 +31,11 @@ e.g., by running `ln -s .env.keycloak-auth .env; npm run dev`.
`npm run dev` starts developement version of record-manager-ui at `http://localhost:5173`. In order to login to through keycloak `record-manager` realm needs to be configured: open the `record-manager` realm, under _Clients_ open the `record-manager` client and set
_Valid redirect URIs_ (by default it should be `http://localhost:5173/*`) and _Web Origins_ (by default it should be `http://localhost:5173`).

#### Additional configuration parameters

The environment variable `INTERNAL_RECORD_MANAGER_SERVER_SERVICE` points to the Record Manager backend. `http://host.docker.internal` can be used to configure the backend running locally on the host computer. See more info in the appropriate .env file, e.g., [keycloak-auth/.env](../deploy/keycloak-auth/.env).


### Running with all Services in Development Mode

This section describes the development scenario when the developer runs all dependent services in development mode.
Expand Down

0 comments on commit 30757d3

Please sign in to comment.