Skip to content
Snippets Groups Projects
Select Git revision
  • 3ae598233dc2280fee8e90038c44c08f24b18b7b
  • master default
  • lip-21w
3 results

customize_initrd

Blame
  • Code owners
    Assign users and groups as approvers for specific file changes. Learn more.
    protokollsystem.j2 6.51 KiB
    SQLALCHEMY_DATABASE_URI = "postgresql://{{app_user}}:@/{{app_name}}"
    SQLALCHEMY_TRACK_MODIFICATIONS = False
    
    from secret_config import secret_key as SECRET_KEY, security_key as SECURITY_KEY
    
    DEBUG = False
    
    MAIL_ACTIVE = {{ protokolle_mail }}
    MAIL_FROM = "{{ protokolle_mail_from }}"
    MAIL_HOST = "{{ protokolle_mail_host }}"
    MAIL_USER = "{{ protokolle_mail_user }}"
    MAIL_PASSWORD = "{{ protokolle_mail_password }}"
    {% if protokolle_mail_tls == 'tls' %}
    MAIL_USE_TLS = True
    MAIL_USE_STARTTLS = False
    {% elif protokolle_mail_tls == 'starttls' %}
    MAIL_USE_TLS = False
    MAIL_USE_STARTTLS = True
    {% else %}
    MAIL_USE_TLS = False
    MAIL_USE_STARTTLS = False
    {% endif %}
    
    CELERY_BROKER_URL = "{{ protokolle_celery_broker }}"
    CELERY_TASK_SERIALIZER = "pickle"
    CELERY_ACCEPT_CONTENT = ["pickle"]
    
    {% if protokolle_sentry_dsn is defined %}
    SENTRY_DSN = "{{protokolle_sentry_dsn}}"
    {% endif %}
    
    SERVER_NAME = "{{ protokolle_url_root }}"
    PREFERRED_URL_SCHEME = "{{ protokolle_url_proto }}"
    URL_ROOT = "{{ protokolle_url_root }}"
    URL_PROTO = "{{ protokolle_url_proto }}"
    URL_PATH = "{{ protokolle_url_path }}"
    URL_PARAMS = ""
    
    {% if cdn_url is defined %}
    CDN_URL = "{{cdn_url}}"
    {% endif %}
    
    PRINTING_ACTIVE = {{ protokolle_printing }}
    PRINTING_SERVER = "{{ protokolle_printing_server }}"
    PRINTING_USER = "{{ protokolle_printing_user }}"
    PRINTING_PRINTERS = {
    {% for p in protokolle_printing_printers %}
    	"{{ p.printer }}": [
    {% for o in p.options %}
    		"{{ o }}",
    {% endfor %}
    	],
    {% endfor %}
    }
    
    ETHERPAD_ACTIVE = {{ protokolle_etherpad }}
    ETHERPAD_URL = "{{ protokolle_etherpad_url }}"
    ETHERPAD_API_URL = "{{ protokolle_etherpad_api_url }}"
    ETHERPAD_APIKEY = "{{ protokolle_etherpad_apikey }}"
    EMPTY_ETHERPAD = """Welcome to Etherpad!
    
    This pad text is synchronized as you type, so that everyone viewing this page sees the same text. This allows you to collaborate seamlessly on documents!
    
    Get involved with Etherpad at https://etherpad.org
    
    """
    
    WIKI_ACTIVE = {{ protokolle_wiki }}
    WIKI_TYPE = "{{ protokolle_wiki_type }}"
    WIKI_API_URL = "{{ protokolle_wiki_api }}"
    WIKI_ANONYMOUS = {{ protokolle_wiki_anonymous }}
    WIKI_USER = "{{ protokolle_wiki_user }}"
    WIKI_PASSWORD = "{{ protokolle_wiki_password }}"
    WIKI_DOMAIN = "{{ protokolle_wiki_domain }}"
    
    CALENDAR_ACTIVE = {{ protokolle_calendar }}
    CALENDAR_URL = "{{ protokolle_calendar_url }}"
    CALENDAR_DEFAULT_DURATION = 3
    CALENDAR_MAX_REQUESTS = 10
    CALENDAR_TIMEZONE_MAP = {
        "CET": "Europe/Berlin",
        "CEST": "Europe/Berlin",
    }
    
    SESSION_PROTECTION = "strong"
    
    from common.auth import LdapManager, ADManager
    AUTH_MAX_DURATION = {{ protokolle_auth_max_duration }}
    AUTH_BACKENDS = [
    {% for auth in protokolle_auth_backends %}
        {{ auth.type }}(
            {% if auth.host is defined %}
            host="{{ auth.host }}",
            {% elif auth.hosts is defined %}
            host=(
            {% for host in auth.hosts %}
            "{{host}}",
            {% endfor %}
            )
            {% endif %}
            domain="{{ auth.domain }}",
            user_dn="{{ auth.user_dn }}",
            group_dn="{{ auth.group_dn }}",
            ca_cert="{{ auth.ca_cert }}"),
    {% endfor %}
    ]
    
    OBSOLETION_WARNING = "{{ protokolle_auth_obsoletion_warning }}"
    
    ERROR_CONTEXT_LINES = 3
    
    PAGE_LENGTH = 20
    PAGE_DIFF = 3
    
    MAX_INDEX_DAYS = 14
    MAX_PAST_INDEX_DAYS = 2
    MAX_PAST_INDEX_DAYS_BEFORE_REMINDER = 14
    
    HTML_LEVEL_OFFSET = 3
    
    ADMIN_MAIL = "{{ protokolle_admin_mail }}"
    ADMIN_GROUP = "{{ protokolle_admin_group }}"
    
    PARSER_LAZY = False
    
    FUZZY_MIN_SCORE = 90
    
    {#
    FONTS = {
        "main": {
            "extension": ".otf",
            "path": "/usr/share/fonts/OTF/",
            "regular": "NimbusSans-Regular",
            "bold": "NimbusSans-Bold",
            "italic": "NimbusSans-Oblique",
            "bolditalic": "NimbusSans-BoldOblique"
        },
        "roman": {
            "extension": ".otf",
            "path": "/usr/share/fonts/OTF/",
            "regular": "NimbusRoman-Regular",
            "bold": "NimbusRoman-Bold",
            "italic": "NimbusRoman-Italic",
            "bolditalic": "NimbusRoman-BoldItalic"
        },
        "sans": {
            "extension": ".otf",
            "path": "/usr/share/fonts/OTF/",
            "regular": "NimbusSans-Regular",
            "bold": "NimbusSans-Bold",
            "italic": "NimbusSans-Oblique",
            "bolditalic": "NimbusSans-BoldOblique"
        },
        "mono": {
            "extension": ".otf",
            "path": "/usr/share/fonts/OTF/",
            "regular": "NimbusMonoPS-Regular",
            "bold": "NimbusMonoPS-Bold",
            "italic": "NimbusMonoPS-Italic",
            "bolditalic": "NimbusMonoPS-BoldItalic"
        }
    }
    #}
    
    FONTS = {
        "main": {
            "extension": ".pfb",
            "path": "/usr/share/fonts/type1/gsfonts/",
            "regular": "n019003l",
            "bold": "n019004l",
            "italic": "n019023l",
            "bolditalic": "n019024l"
        },
        "roman": {
            "extension": ".pfb",
            "path": "/usr/share/fonts/type1/gsfonts/",
            "regular": "n021003l",
            "bold": "n021004l",
            "italic": "n021023l",
            "bolditalic": "n021024l"
        },
        "sans": {
            "extension": ".pfb",
            "path": "/usr/share/fonts/type1/gsfonts/",
            "regular": "n019003l",
            "bold": "n019004l",
            "italic": "n019023l",
            "bolditalic": "n019024l"
        },
        "mono": {
            "extension": ".pfb",
            "path": "/usr/share/fonts/type1/gsfonts/",
            "regular": "n022003l",
            "bold": "n022004l",
            "italic": "n022023l",
            "bolditalic": "n022024l"
        }
    }
    
    DOCUMENTS_PATH = "documents"
    
    PRIVATE_KEYWORDS = ["private", "internal", "privat", "intern"]
    
    LATEX_BULLETPOINTS = [
        r"\textbullet",
        r"\normalfont \bfseries \textendash",
        r"$\circ$",
        r"\textperiodcentered"
    ]
    
    {% if protokolle_latex_local_templates %}
    LATEX_LOCAL_TEMPLATES = "{{ protokolle_latex_local_templates }}"
    {% endif %}
    {% if protokolle_latex_logo_template %}
    LATEX_LOGO_TEMPLATE = "{{ protokolle_latex_logo_template }}"
    {% endif %}
    {% if protokolle_latex_geometry %}
    LATEX_GEOMETRY = "{{ protokolle_latex_geometry }}"
    {% endif %}
    {% if protokolle_latex_pagestyle %}
    LATEX_PAGESTYLE = "{{ protokolle_latex_pagestyle }}"
    {% endif %}
    {% if protokolle_latex_packages %}
    LATEX_ADDITIONAL_PACKAGES = ["{{ protokolle_latex_packages|join('", "') }}"]
    {% endif %}
    {% if protokolle_latex_header_footer %}
    LATEX_HEADER_FOOTER = True
    {% elif protokolle_latex_header_footer == False %}
    LATEX_HEADER_FOOTER = False
    {% endif %}
    
    LATEX_TEMPLATES = {
    {% for logo in protokolle_logos %}
        "{{ logo.id }}": {
            "name": "{{ logo.name }}",
            "logo": "{{ logo.tex }}",
        },
    {% endfor %}
    }
    
    #def dummy_todomail_provider():
    #    return {"example": ("Name", "mail@example.com")}
    #
    #ADDITIONAL_TODOMAIL_PROVIDERS = [
    #    dummy_todomail_provider
    #]