Provides and API to manage the locations inside a prison.
This is straight-forward as authentication is delegated down to the calling services in dev
environment.
Environment variables to be set are as follows:
API_BASE_URL_OAUTH=https://sign-in-dev.hmpps.service.justice.gov.uk/auth
API_BASE_URL_PRISON=https://prison-api-dev.prison.service.justice.gov.uk
LOCATIONS_INSIDE_PRISON_API_CLIENT_ID=[choose a suitable hmpps-auth client]
LOCATIONS_INSIDE_PRISON_API_CLIENT_SECRET=
Start the database and other required services via docker-compose with:
docker compose up
Then run the API.
docker compose --profile include-api up --build
Architecture decision records start here
Run:
./gradlew koverHtmlReport
Then view output file for coverage report.
The project is sync with https://github.com/ministryofjustice/hmpps-template-kotlin
Sync date: 25/10/2024
sync commit: 7426643351775e175fc5e77101fd9226fe66ef86
Check if remote repository is added by git remote -v
.
if repository is not present run git remote add hmpps-kotlin-tamplate git@github.com:ministryofjustice/hmpps-template-kotlin.git
.
Fetch the newest changes from hmpps-kotlin-template calling git fetch hmpps-kotlin-template
.
Find out missing commits https://github.com/ministryofjustice/hmpps-template-kotlin/commits/main/ following sync commit
above.
Cherry Pick the changes by calling git cherry-pick <<commit_id>>..<<commit_id>>
if you want to Cherry pick only one commit call git cherry-pick <<commit_id>>
Resolve the conflict and update sync date and sync commit in README.md to guide the next person on what was done.