Skip to content

Commit

Permalink
Keycloak docs fix wrong link and add small enhancement
Browse files Browse the repository at this point in the history
  • Loading branch information
jedla97 committed Dec 14, 2023
1 parent 08bff7a commit 6dc006f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
6 changes: 3 additions & 3 deletions docs/src/main/asciidoc/security-keycloak-admin-client.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ To learn more about the Keycloak Admin Client, please refer to its https://www.k

:prerequisites-docker:
include::{includes}/prerequisites.adoc[]
* https://www.keycloak.org/docs/latest/server_installation/index.html[Keycloak]
* https://www.keycloak.org[Keycloak]

== Creating the Project

Check warning on line 25 in docs/src/main/asciidoc/security-keycloak-admin-client.adoc

View workflow job for this annotation

GitHub Actions / Linting with Vale

[vale] reported by reviewdog 🐶 [Quarkus.Headings] Use sentence-style capitalization in 'Creating the Project'. Raw Output: {"message": "[Quarkus.Headings] Use sentence-style capitalization in 'Creating the Project'.", "location": {"path": "docs/src/main/asciidoc/security-keycloak-admin-client.adoc", "range": {"start": {"line": 25, "column": 4}}}, "severity": "INFO"}

Expand Down Expand Up @@ -124,8 +124,8 @@ import org.keycloak.admin.client.Keycloak;
import org.keycloak.admin.client.KeycloakBuilder;
import org.keycloak.representations.idm.RoleRepresentation;
import jakarta.annotations.PostConstruct;
import jakarta.annotations.PreConstruct;
import jakarta.annotation.PostConstruct;
import jakarta.annotation.PreDestroy;
import jakarta.ws.rs.GET;
import jakarta.ws.rs.Path;
import java.util.List;
Expand Down
8 changes: 5 additions & 3 deletions docs/src/main/asciidoc/security-keycloak-authorization.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ Please see https://www.keycloak.org/docs/latest/authorization_services/index.htm
:prerequisites-docker:
include::{includes}/prerequisites.adoc[]
* https://stedolan.github.io/jq/[jq tool]
* https://www.keycloak.org/docs/latest/server_installation/index.html[Keycloak]
* https://www.keycloak.org[Keycloak]
== Architecture
Expand Down Expand Up @@ -115,7 +115,7 @@ import jakarta.inject.Inject;
import jakarta.ws.rs.GET;
import jakarta.ws.rs.Path;
import org.jboss.resteasy.annotations.cache.NoCache;
import org.jboss.resteasy.reactive.NoCache;
import io.quarkus.security.identity.SecurityIdentity;
Expand Down Expand Up @@ -199,6 +199,8 @@ NOTE: Adding a `%prod.` profile prefix to `quarkus.oidc.auth-server-url` ensures
NOTE: By default, applications using the `quarkus-oidc` extension are marked as a `service` type application (see `quarkus.oidc.application-type`). This extension also supports only `web-app` type applications but only if the access token returned as part of the authorization code grant response is marked as a source of roles: `quarkus.oidc.roles.source=accesstoken` (`web-app` type applications check ID token roles by default).

Check warning on line 200 in docs/src/main/asciidoc/security-keycloak-authorization.adoc

View workflow job for this annotation

GitHub Actions / Linting with Vale

[vale] reported by reviewdog 🐶 [Quarkus.TermsSuggestions] Depending on the context, consider using 'because' or 'while' rather than 'as'. Raw Output: {"message": "[Quarkus.TermsSuggestions] Depending on the context, consider using 'because' or 'while' rather than 'as'.", "location": {"path": "docs/src/main/asciidoc/security-keycloak-authorization.adoc", "range": {"start": {"line": 200, "column": 67}}}, "severity": "INFO"}
NOTE: The configurated `quarkus-realm.json` file for this example can be found in https://github.com/quarkusio/quarkus-quickstarts/blob/main/security-keycloak-authorization-quickstart/config/quarkus-realm.json[quarkus-quickstarts/security-keycloak-authorization-quickstart/config]

Check warning on line 202 in docs/src/main/asciidoc/security-keycloak-authorization.adoc

View workflow job for this annotation

GitHub Actions / Linting with Vale

[vale] reported by reviewdog 🐶 [Quarkus.Headings] Use sentence-style capitalization in 'Starting and Configuring the Keycloak Server'. Raw Output: {"message": "[Quarkus.Headings] Use sentence-style capitalization in 'Starting and Configuring the Keycloak Server'.", "location": {"path": "docs/src/main/asciidoc/security-keycloak-authorization.adoc", "range": {"start": {"line": 202, "column": 275}}}, "severity": "INFO"}
== Starting and Configuring the Keycloak Server
NOTE: Do not start the Keycloak server when you run the application in a dev mode - `Dev Services for Keycloak` will launch a container. See <<keycloak-dev-mode,Running the Application in Dev mode>> section below for more information.

Check warning on line 206 in docs/src/main/asciidoc/security-keycloak-authorization.adoc

View workflow job for this annotation

GitHub Actions / Linting with Vale

[vale] reported by reviewdog 🐶 [Quarkus.TermsWarnings] Consider using 'start' or 'open' rather than 'launch' unless updating existing content that uses the term. Raw Output: {"message": "[Quarkus.TermsWarnings] Consider using 'start' or 'open' rather than 'launch' unless updating existing content that uses the term.", "location": {"path": "docs/src/main/asciidoc/security-keycloak-authorization.adoc", "range": {"start": {"line": 206, "column": 107}}}, "severity": "WARNING"}
Expand All @@ -210,7 +212,7 @@ To start a Keycloak Server you can use Docker and just run the following command
docker run --name keycloak -e KEYCLOAK_ADMIN=admin -e KEYCLOAK_ADMIN_PASSWORD=admin -p 8543:8443 -v "$(pwd)"/config/keycloak-keystore.jks:/etc/keycloak-keystore.jks quay.io/keycloak/keycloak:{keycloak.version} start --hostname-strict=false --https-key-store-file=/etc/keycloak-keystore.jks
----
where `keycloak.version` should be set to `17.0.0` or higher.
where `keycloak.version` should be set to `23.0.0` or higher and the `keycloak-keystore.jks` can be found in https://github.com/quarkusio/quarkus-quickstarts/blob/main/security-keycloak-authorization-quickstart/config/keycloak-keystore.jks[quarkus-quickstarts/security-keycloak-authorization-quickstart/config]
You should be able to access your Keycloak Server at https://localhost:8543[localhost:8543].

Check warning on line 217 in docs/src/main/asciidoc/security-keycloak-authorization.adoc

View workflow job for this annotation

GitHub Actions / Linting with Vale

[vale] reported by reviewdog 🐶 [Quarkus.TermsSuggestions] Depending on the context, consider using 'because' or 'while' rather than 'as'. Raw Output: {"message": "[Quarkus.TermsSuggestions] Depending on the context, consider using 'because' or 'while' rather than 'as'.", "location": {"path": "docs/src/main/asciidoc/security-keycloak-authorization.adoc", "range": {"start": {"line": 217, "column": 86}}}, "severity": "INFO"}
Expand Down

0 comments on commit 6dc006f

Please sign in to comment.