Configuration

The configuration of Open-Needs Server is stored in a file called settings.toml.

Example

This is the used default configuration file of Open-Needs Server.

[server]
server = "127.0.0.1"
port = 9595
log_level = "DEBUG"
open_browser = false

extensions = [
    # DataModel extensions
    "open_needs_server.extensions:OrganizationExtension",
    "open_needs_server.extensions:ProjectExtension",
    "open_needs_server.extensions:DomainExtension",
    "open_needs_server.extensions:NeedExtension",
    # Authentication extensions
    "open_needs_server.extensions:UserSecurityExtension",
    # Feature extensions
    "open_needs_server.extensions:FilterExtension",
    "open_needs_server.extensions:ExtensionViewerExtension",
    "open_needs_server.extensions:OnsAdminExtension",
    "open_needs_server.extensions:WelcomePage",
    "open_needs_server.extensions:EventLoggerExtension",
]

[database]
sql_string = "sqlite+aiosqlite:///./ons.db"

[admin]

    [admin.Organizations]
    model = "open_needs_server.extensions.organization.models:OrganizationModel"
    columns = ["id", "title", "projects", "users"]
    name = "Organization"
    icon = "fa-solid fa-building"

    [admin.Projects]
    model = "open_needs_server.extensions.project.models:ProjectModel"
    columns = ["id", "title", "organization", "domains", "needs"]
    name = "Project"
    icon = "fa-solid fa-box-open"

    [admin.Domains]
    model = "open_needs_server.extensions.domain.models:DomainModel"
    columns = ["id", "title", "description", "jsonschema"]
    name = "Domain"
    icon = "fa-solid fa-ruler"

    [admin.Needs]
    model = "open_needs_server.extensions.need.models:NeedModel"
    columns = ["id", "title", "project", "description", "options", "references"]
    name = "Need"
    icon = "fa-solid fa-note-sticky"

    [admin.Users]
    model = "open_needs_server.extensions.user_security.models:UserModel"
    columns = ["id", "email", "is_verified", "is_active", "is_superuser"]
    name = "User"
    icon = "fa-solid fa-user"

    [admin.Roles]
    model = "open_needs_server.extensions.user_security.models:RoleModel"
    columns = ["id", "name", "users"]
    name = "Role"
    icon = "fa-solid fa-address-card"

Technical details

Open-Needs Server is using the library Dynaconf for configuration handling.


Last update: Jul 05, 2022