mirror of
https://gitlab.crans.org/bde/nk20
synced 2025-03-28 08:31:12 +00:00
Added configusation for OpenID support, along with installation information
This commit is contained in:
parent
c630a3fbd5
commit
4563b2b640
14
README.md
14
README.md
@ -58,7 +58,13 @@ Bien que cela permette de créer une instance sur toutes les distributions,
|
|||||||
(env)$ ./manage.py createsuperuser # Création d'un⋅e utilisateur⋅rice initial
|
(env)$ ./manage.py createsuperuser # Création d'un⋅e utilisateur⋅rice initial
|
||||||
```
|
```
|
||||||
|
|
||||||
6. Enjoy :
|
6. (Optionnel) **Création d'une clé privée OpenID Connect**
|
||||||
|
|
||||||
|
Pour activer le support d'OpenID Connect, il faut générer une clé privée, par
|
||||||
|
exemple avec openssl (`openssl genrsa -out oidc.key 4096`), et renseigner son
|
||||||
|
emplacement dans `OIDC_RSA_PRIVATE_KEY` (par défaut `/var/secrets/oidc.key`)
|
||||||
|
|
||||||
|
7. Enjoy :
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
(env)$ ./manage.py runserver 0.0.0.0:8000
|
(env)$ ./manage.py runserver 0.0.0.0:8000
|
||||||
@ -228,6 +234,12 @@ Sinon vous pouvez suivre les étapes décrites ci-dessous.
|
|||||||
(env)$ ./manage.py check # pas de bêtise qui traine
|
(env)$ ./manage.py check # pas de bêtise qui traine
|
||||||
(env)$ ./manage.py migrate
|
(env)$ ./manage.py migrate
|
||||||
|
|
||||||
|
7. **Création d'une clé privée OpenID Connect**
|
||||||
|
|
||||||
|
Pour activer le support d'OpenID Connect, il faut générer une clé privée, par
|
||||||
|
exemple avec openssl (`openssl genrsa -out oidc.key 4096`), et renseigner son
|
||||||
|
emplacement dans `OIDC_RSA_PRIVATE_KEY` (par défaut `/var/secrets/oidc.key`)
|
||||||
|
|
||||||
7. *Enjoy \o/*
|
7. *Enjoy \o/*
|
||||||
|
|
||||||
### Installation avec Docker
|
### Installation avec Docker
|
||||||
|
@ -268,6 +268,10 @@ OAUTH2_PROVIDER = {
|
|||||||
'OAUTH2_VALIDATOR_CLASS': "permission.scopes.PermissionOAuth2Validator",
|
'OAUTH2_VALIDATOR_CLASS': "permission.scopes.PermissionOAuth2Validator",
|
||||||
'REFRESH_TOKEN_EXPIRE_SECONDS': timedelta(days=14),
|
'REFRESH_TOKEN_EXPIRE_SECONDS': timedelta(days=14),
|
||||||
'PKCE_REQUIRED': False, # PKCE (fix a breaking change of django-oauth-toolkit 2.0.0)
|
'PKCE_REQUIRED': False, # PKCE (fix a breaking change of django-oauth-toolkit 2.0.0)
|
||||||
|
'OIDC_ENABLED': True,
|
||||||
|
'OIDC_RSA_PRIVATE_KEY':
|
||||||
|
os.getenv('OIDC_RSA_PRIVATE_KEY', '/var/secrets/oidc.key'),
|
||||||
|
'SCOPES': { 'openid': "OpenID Connect scope" },
|
||||||
}
|
}
|
||||||
|
|
||||||
# Take control on how widget templates are sourced
|
# Take control on how widget templates are sourced
|
||||||
|
Loading…
x
Reference in New Issue
Block a user