Skip to content

Commit

Permalink
review comment updates
Browse files Browse the repository at this point in the history
  • Loading branch information
farrell-m committed Jun 7, 2024
1 parent 0af37ae commit 96da16a
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 8 deletions.
9 changes: 8 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,11 @@ In order to generate the interface and models a build can be run on the overall

## data-service

the data-service implements the api interface generated in the data-api subproject.
the data-service implements the api interface generated in the data-api subproject.

## Common Components

This API uses components from the [LAA CCMS Common Library](https://github.com/ministryofjustice/laa-ccms-spring-boot-common):

- [laa-ccms-spring-boot-plugin](https://github.com/ministryofjustice/laa-ccms-spring-boot-common?tab=readme-ov-file#laa-ccms-spring-boot-gradle-plugin-for-java--spring-boot-projects)
- [laa-ccms-spring-boot-starter-auth](https://github.com/ministryofjustice/laa-ccms-spring-boot-common/tree/main/laa-ccms-spring-boot-starters/laa-ccms-spring-boot-starter-auth)
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
plugins {
id 'net.researchgate.release' version '3.0.2'
id 'uk.gov.laa.ccms.springboot.laa-ccms-spring-boot-gradle-plugin' version '0.0.2' apply false
id 'uk.gov.laa.ccms.springboot.laa-ccms-spring-boot-gradle-plugin' version '0.0.3' apply false
}

subprojects {
Expand Down
2 changes: 1 addition & 1 deletion data-service/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ dependencies {
implementation 'org.springframework.boot:spring-boot-starter-web'

//Enable access token authentication
implementation 'uk.gov.laa.ccms.springboot:laa-ccms-spring-boot-starter-auth:0.0.3-b2f8726-SNAPSHOT'
implementation 'uk.gov.laa.ccms.springboot:laa-ccms-spring-boot-starter-auth'

//Enable Swagger UI
implementation 'org.springdoc:springdoc-openapi-starter-webmvc-ui:2.5.0'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,6 @@ static void properties(DynamicPropertyRegistry registry) {
registry.add("spring.datasource.url", oracleContainerSingleton.getOracleContainer()::getJdbcUrl);
registry.add("spring.datasource.username", oracleContainerSingleton.getOracleContainer()::getUsername);
registry.add("spring.datasource.password", oracleContainerSingleton.getOracleContainer()::getPassword);

registry.add("laa.ccms.springboot.starter.auth.authentication-header", () -> "Authorization");
registry.add("laa.ccms.springboot.starter.auth.authorized-clients", () -> "[{\"name\":\"caab-ui\",\"roles\":[\"ALL\"],\"token\":\"d594f93f-e767-4b88-a9e9-2913441edfba\"}]");
registry.add("laa.ccms.springboot.starter.auth.authorized-roles", () -> "[{\"name\":\"ALL\",\"URIs\":[\"/**\"]}]");
registry.add("laa.ccms.springboot.starter.auth.unprotected-uris", () -> "[\"\"]");
}
}

20 changes: 20 additions & 0 deletions data-service/src/integrationTest/resources/application.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
laa.ccms.springboot.starter.auth:
authentication-header: "Authorization"
authorized-clients: '[
{
"name": "integration-test-runner",
"roles": [
"ALL"
],
"token": "d594f93f-e767-4b88-a9e9-2913441edfba"
}
]'
authorized-roles: '[
{
"name": "ALL",
"URIs": [
"/**"
]
}
]'
unprotected-uris: [ "/swagger-ui.html", "/swagger-ui/**", "/v3/api-docs/**", "/favicon.ico", "/open-api-specification.yml"]

0 comments on commit 96da16a

Please sign in to comment.