Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Nov 9, 2024
1 parent b535c11 commit e5c5768
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions fastapi_keycloak_middleware/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,9 @@ def setup_keycloak_middleware( # pylint: disable=too-many-arguments
:param add_swagger_auth: Whether to add OpenID Connect authentication to the OpenAPI
schema. Defaults to False.
:type add_swagger_auth: bool, optional
:param swagger_openId_base_url: Base URL for the OpenID Connect configuration that will be used
by the Swagger UI. This parameter allows you to specify a different base URL than
the one in keycloak_configuration.url. This is particularly useful in Docker
:param swagger_openId_base_url: Base URL for the OpenID Connect configuration that will be used
by the Swagger UI. This parameter allows you to specify a different base URL than
the one in keycloak_configuration.url. This is particularly useful in Docker
container scenarios where the internal and external URLs differ.
For example, inside a Docker container network, Keycloak's OpenID configuration
Expand All @@ -78,13 +78,13 @@ def setup_keycloak_middleware( # pylint: disable=too-many-arguments
However, external clients like Swagger UI cannot resolve host.docker.internal.
In this case, you would set:
- keycloak_configuration.url:
- keycloak_configuration.url:
-- "http://host.docker.internal:8080" (for internal communication)
- swagger_openId_base_url:
- swagger_openId_base_url:
-- "http://localhost:8080" (for Swagger UI access)
If not specified, defaults to using keycloak_configuration.url.
:type swagger_openId_base_url: str, optional
:type swagger_openId_base_url: str, optional
:param swagger_auth_scopes: Scopes to use for the Swagger UI authentication.
Defaults to ['openid', 'profile'].
:type swagger_auth_scopes: typing.List[str], optional
Expand Down

0 comments on commit e5c5768

Please sign in to comment.