Add OSB settings
This commit is contained in:
parent
da90003143
commit
b2c5317da2
4 changed files with 12 additions and 0 deletions
|
|
@ -68,3 +68,7 @@ SERVALA_ODOO_USERNAME=''
|
||||||
SERVALA_ODOO_PASSWORD=''
|
SERVALA_ODOO_PASSWORD=''
|
||||||
# Helpdesk team ID for support tickets in Odoo. Defaults to 5.
|
# Helpdesk team ID for support tickets in Odoo. Defaults to 5.
|
||||||
SERVALA_ODOO_HELPDESK_TEAM_ID='5'
|
SERVALA_ODOO_HELPDESK_TEAM_ID='5'
|
||||||
|
|
||||||
|
# OSB API authentication settings
|
||||||
|
SERVALA_OSB_USERNAME=''
|
||||||
|
SERVALA_OSB_PASSWORD=''
|
||||||
|
|
|
||||||
|
|
@ -84,3 +84,5 @@ def check_servala_production_settings(app_configs, **kwargs):
|
||||||
id="servala.W001",
|
id="servala.W001",
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
return errors
|
||||||
|
|
|
||||||
|
|
@ -75,6 +75,9 @@ EMAIL_USE_SSL = os.environ.get("SERVALA_EMAIL_SSL", "False") == "True"
|
||||||
|
|
||||||
SERVALA_DEFAULT_ORIGIN = int(os.environ.get("SERVALA_DEFAULT_ORIGIN", "1"))
|
SERVALA_DEFAULT_ORIGIN = int(os.environ.get("SERVALA_DEFAULT_ORIGIN", "1"))
|
||||||
|
|
||||||
|
OSB_USERNAME = os.environ.get("SERVALA_OSB_USERNAME")
|
||||||
|
OSB_PASSWORD = os.environ.get("SERVALA_OSB_PASSWORD")
|
||||||
|
|
||||||
SOCIALACCOUNT_PROVIDERS = {
|
SOCIALACCOUNT_PROVIDERS = {
|
||||||
"openid_connect": {
|
"openid_connect": {
|
||||||
"APPS": [
|
"APPS": [
|
||||||
|
|
@ -159,10 +162,12 @@ INSTALLED_APPS = [
|
||||||
"allauth.socialaccount.providers.openid_connect",
|
"allauth.socialaccount.providers.openid_connect",
|
||||||
"auditlog",
|
"auditlog",
|
||||||
"servala.core",
|
"servala.core",
|
||||||
|
"servala.api",
|
||||||
]
|
]
|
||||||
|
|
||||||
MIDDLEWARE = [
|
MIDDLEWARE = [
|
||||||
"django.middleware.security.SecurityMiddleware",
|
"django.middleware.security.SecurityMiddleware",
|
||||||
|
"servala.api.authentication.OSBBasicAuthentication",
|
||||||
"django.contrib.sessions.middleware.SessionMiddleware",
|
"django.contrib.sessions.middleware.SessionMiddleware",
|
||||||
"django.middleware.common.CommonMiddleware",
|
"django.middleware.common.CommonMiddleware",
|
||||||
"django.middleware.csrf.CsrfViewMiddleware",
|
"django.middleware.csrf.CsrfViewMiddleware",
|
||||||
|
|
|
||||||
|
|
@ -20,6 +20,7 @@ urlpatterns = [
|
||||||
# - accounts/keycloak/login/callback/
|
# - accounts/keycloak/login/callback/
|
||||||
path("accounts/", include("allauth.urls")),
|
path("accounts/", include("allauth.urls")),
|
||||||
path("admin/", admin.site.urls),
|
path("admin/", admin.site.urls),
|
||||||
|
path("", include("servala.api.urls")),
|
||||||
]
|
]
|
||||||
|
|
||||||
# Serve static and media files in development
|
# Serve static and media files in development
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue