-
Notifications
You must be signed in to change notification settings - Fork 65
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #549 from tmnvvv/test/demo-memory-fix-update
Test/demo memory fix update
- Loading branch information
Showing
27 changed files
with
743 additions
and
135 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import {Log, UserManager} from 'oidc-client-ts'; | ||
|
||
Log.setLogger(console); | ||
Log.setLevel(Log.ERROR); | ||
|
||
const url = window.location.origin; | ||
|
||
export const settings = { | ||
authority: process.env.VUE_APP_DOCHUB_AUTHORITY_SERVER, | ||
client_id: process.env.VUE_APP_DOCHUB_AUTHORITY_CLIENT_ID, | ||
redirect_uri: new URL('/login', url), | ||
post_logout_redirect_uri: new URL('/logout', url), | ||
response_type: 'code', | ||
scope: 'openid', | ||
response_mode: 'fragment', | ||
automaticSilentRenew: true | ||
}; | ||
|
||
export { | ||
Log, | ||
UserManager | ||
}; |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# Ролевая модель | ||
|
||
Ролевая модель - позволяет разграничивать доступы к элементам архитектуры. | ||
Управление ролями пользователей происходит на стороне keycloack. | ||
|
||
Для включения работы с ролевой моделью требуется установить следующий флаг: | ||
VUE_APP_DOCHUB_ROLES_MODEL=y | ||
|
||
Описание ролей осуществляется в корневом файле roles.yaml | ||
Пример описания правил доступа: | ||
``` | ||
roles: | ||
users: | ||
- '^kadzo.v2023.data_objects*$' // Правило представляет собой регулярное выражение | ||
- '^ecogroup.berezka.data_objects[a-zA-Z\._0-9]*$' | ||
uek: | ||
- '^kadzo\.v2023\.kb_systems[a-zA-Z\._0-9]*$' | ||
- '^ecogroup.berezka.kb[a-zA-Z\._0-9]*$' | ||
default: | ||
- '^kadzo\.v2023\.data_objects*$' | ||
``` | ||
VUE_APP_DOCHUB_ROLES=file:///workspace/sberauto/roles.yaml | ||
|
||
Если пользователь имеет несколько ролей, то наборы правил объединяются. | ||
|
||
Для работы ролевой модели требуется дополнительно указать в файле .env несколько параметров: | ||
|
||
``` | ||
Указываем путь до сервера аутентификации с указанием realms | ||
VUE_APP_DOCHUB_AUTHORITY_SERVER=https://dochub-server.ru/realms/dochub | ||
Указываем client id, например: dochub | ||
VUE_APP_DOCHUB_AUTHORITY_CLIENT_ID={CLIENTID} | ||
{PUBLIC KEY} - указываем public key, смотрим настройки keycloack | ||
VUE_APP_DOCHUB_AUTH_PUBLIC_KEY=-----BEGIN PUBLIC KEY-----{PUBLIC KEY}-----END PUBLIC KEY----- | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.