Skip to content

Commit

Permalink
(inclusion_connect) mise à jour des urls
Browse files Browse the repository at this point in the history
  • Loading branch information
vincentporte committed Oct 17, 2023
1 parent 4622342 commit dcb8e58
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 9 deletions.
1 change: 0 additions & 1 deletion .env.template
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ SIB_API_KEY=__key_to_be_set__

# for Inclusion Connect
INCLUSION_CONNECT_BASE_URL=http://127.0.0.1:8080
INCLUSION_CONNECT_REALM=local
INCLUSION_CONNECT_CLIENT_ID=local_inclusion_connect
INCLUSION_CONNECT_CLIENT_SECRET=__key_to_be_set__

Expand Down
1 change: 0 additions & 1 deletion config/settings/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,6 @@
# Inclusion Connect
# ------------------------------------------------------------------------------
INCLUSION_CONNECT_BASE_URL = os.getenv("INCLUSION_CONNECT_BASE_URL")
INCLUSION_CONNECT_REALM = os.getenv("INCLUSION_CONNECT_REALM")
INCLUSION_CONNECT_CLIENT_ID = os.getenv("INCLUSION_CONNECT_CLIENT_ID")
INCLUSION_CONNECT_CLIENT_SECRET = os.getenv("INCLUSION_CONNECT_CLIENT_SECRET")

Expand Down
13 changes: 6 additions & 7 deletions lacommunaute/inclusion_connect/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,14 @@
INCLUSION_CONNECT_CLIENT_ID = settings.INCLUSION_CONNECT_CLIENT_ID
INCLUSION_CONNECT_CLIENT_SECRET = settings.INCLUSION_CONNECT_CLIENT_SECRET

INCLUSION_CONNECT_REALM_ENDPOINT = "{base_url}/realms/{realm}/protocol/openid-connect".format(
INCLUSION_CONNECT_ENDPOINT = "{base_url}/auth".format(
base_url=settings.INCLUSION_CONNECT_BASE_URL,
realm=settings.INCLUSION_CONNECT_REALM,
)
INCLUSION_CONNECT_ENDPOINT_AUTHORIZE = f"{INCLUSION_CONNECT_REALM_ENDPOINT}/auth"
INCLUSION_CONNECT_ENDPOINT_REGISTRATIONS = f"{INCLUSION_CONNECT_REALM_ENDPOINT}/registrations"
INCLUSION_CONNECT_ENDPOINT_TOKEN = f"{INCLUSION_CONNECT_REALM_ENDPOINT}/token"
INCLUSION_CONNECT_ENDPOINT_USERINFO = f"{INCLUSION_CONNECT_REALM_ENDPOINT}/userinfo"
INCLUSION_CONNECT_ENDPOINT_LOGOUT = f"{INCLUSION_CONNECT_REALM_ENDPOINT}/logout"
INCLUSION_CONNECT_ENDPOINT_AUTHORIZE = f"{INCLUSION_CONNECT_ENDPOINT}/authorize/"
INCLUSION_CONNECT_ENDPOINT_REGISTRATIONS = f"{INCLUSION_CONNECT_ENDPOINT}/register/"
INCLUSION_CONNECT_ENDPOINT_TOKEN = f"{INCLUSION_CONNECT_ENDPOINT}/token/"
INCLUSION_CONNECT_ENDPOINT_USERINFO = f"{INCLUSION_CONNECT_ENDPOINT}/userinfo/"
INCLUSION_CONNECT_ENDPOINT_LOGOUT = f"{INCLUSION_CONNECT_ENDPOINT}/logout/"

# These expiration times have been chosen arbitrarily.
INCLUSION_CONNECT_TIMEOUT = 60
Expand Down

0 comments on commit dcb8e58

Please sign in to comment.