From cead0f2c1e5301294a90342374ca904aff3dd5a9 Mon Sep 17 00:00:00 2001 From: Fiete Ostkamp Date: Tue, 22 Oct 2024 13:05:53 +0200 Subject: [PATCH] format README Issue-ID: PORTALNG-123 --- README.md | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index a1851ef..2235b42 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,9 @@ Backend for Frontend (BFF) component of the portal-ng. ## Build -You can build and test the application with: + +You can build and test the application with: + ``` sh # Windows gradlew clean build @@ -11,6 +13,7 @@ gradlew clean build ``` ## Test + ``` sh # run all tests ./gradlew test @@ -23,23 +26,29 @@ gradlew clean build ``` ## Generate JAR + To generate one JAR file including also the open-api part the following command can be used + ```sh # generate JAR to /library/build/libs ./gradlew shadowJar ``` ## Publish JAR + To publish the generated JAR file run + ```sh # publish JAR to target repository ./gradlew publish ``` ## Run locally + Currently there are three spring profiles that can be used to run the application (`application.yml`, `application-local.yml` and `application-development.yml`). To launch the application with a specific profile run + ``` sh SPRING_PROFILES_ACTIVE=local ./gradlew app:bootRun # or @@ -48,9 +57,11 @@ export SPRING_PROFILES_ACTIVE=local ``` ## Development + You can run the service locally for evaluation or development purposes using the provided `docker-compose.yml` file in the development folder. This will launch a Keycloak and a Postgres db in the background. To start the service execute the `run.sh` in the development folder: + ```sh development/run.sh ``` @@ -59,10 +70,11 @@ Example request against the preferences service can be run in your preferred IDE You can access the Keycloak UI via browser. URL: http://localhost:8080 -**username:** admin +**username:** admin **password:** password To stop the preferences service, Keycloak and the databases run: + ```sh development/stop.sh ```