Skip to content

Latest commit

 

History

History
105 lines (63 loc) · 2.62 KB

File metadata and controls

105 lines (63 loc) · 2.62 KB

Installation guide

Requirements

  • NodeJs v16, you can use nvm to use the version specify in the .nvmrc file.

Configuration

You can lauch the backend with or withour docker. To configure these methods you must have an env file :

  • .env

Copy and rename .env.example.

Label depends on 2 other services from the Cour de cassation : dbsder-api and nlp-pseudonymisation-api. You can lauch these services locally to simulate operation close to production or you can disable theses services from env files. In this case these 2 services are emulated by Label with the storage folder. To do so, follow the Add documents you want to annotate step in the reuser guide or just rename the storage-example folder to storage. To manage local authentication label uses keycloak.

You should take a look at juridependencies to install theses services.

Installation and lauch

Install dependencies with:

yarn

Frontend

With docker:

Start the backend with:

yarn start:client:docker

Without docker:

To lauch the frontend run:

yarn start:client:dev

Then, on your web browser, open http://localhost:55432

Backend

With docker:

Start the backend with:

yarn start:backend:docker

Without docker:

Start the backend:

yarn start:backend:dev

Database

You can init database with :

yarn init:db

This script is lauch with the .env configuration.

Launch scripts

Label contains many scripts, they are listed here You can launch scripts with theses commands :

With docker

docker compose exec labelbk sh -c "cd packages/courDeCassation; sh scripts/runLocalScript.sh ./dist/scripts/myScript.js --myArgument"

Without docker

scripts/runScriptLocally.sh "myScript.js --myArgument"

SSO configuration

Follow the installation guide.

The LABEL application leverages the SSO module as a dependency for its integration with the Single Sign-On (SSO) system. The details of this integration are documented in the README of the SSO module.

The backend exposes the following URLs to interact with the SSO:

  1. /api/sso/login: Endpoint to initiate the login process via SSO.
  2. /api/sso/acs: Endpoint for processing SAML assertions following a successful authentication.
  3. /api/sso/logout: Endpoint to disconnect the user from the SSO.

The attributes returned by the SSO, as well as the roles used by the application, are specified in the configuration file.