bsw@730: -- ========================================================================
bsw@813: -- MANDATORY (MUST BE CAREFULLY CHECKED AND PROPERLY SET!)
bsw@730: -- ========================================================================
bsw@525:
bsw@1667: -- Absolute base url of application
bsw@1667: -- ------------------------------------------------------------------------
bsw@1667: config.absolute_base_url = "https://example.org/"
bsw@1667:
bsw@1667: -- Connection information for the LiquidFeedback database
bsw@1667: -- ------------------------------------------------------------------------
bsw@1667: config.database = { engine='postgresql', dbname='liquid_feedback' }
bsw@1667:
bsw@813: -- Name of this instance, defaults to name of config file
bsw@813: -- ------------------------------------------------------------------------
bsw@1656: config.instance_name = "Example Organisation"
bsw@813:
bsw@1667: -- Information about service provider (HTML)
bsw@813: -- ------------------------------------------------------------------------
bsw@1667: config.app_service_provider = "Snake Oil
10000 Berlin
Germany"
bsw@1656:
bsw@1656: -- Network interface to bind to
bsw@1656: -- ------------------------------------------------------------------------
bsw@1656: -- Available options:
bsw@1656: -- true: bind to localhost (default)
bsw@1656: -- false: bind to all interface
bsw@735: -- ------------------------------------------------------------------------
bsw@1656: -- config.localhost = true
bsw@1656:
bsw@1656: -- Network port to bind to, default port 8080
bsw@1656: -- ------------------------------------------------------------------------
bsw@1656: -- config.port = 8080
bsw@1656:
bsw@1656: -- Serving content via IPV6
bsw@1656: -- ------------------------------------------------------------------------
bsw@1656: -- Available options:
bsw@1656: -- nil or false: do not serve via IPv6 (default)
bsw@1656: -- true: serve via IPv6
bsw@1656: -- ------------------------------------------------------------------------
bsw@1656: -- config.ipv6 = false
bsw@79:
bsw@1667: -- ========================================================================
bsw@1667: -- OPTIONAL
bsw@1667: -- Remove leading -- to use a option
bsw@1667: -- ========================================================================
bsw/jbe@6:
bsw@813: -- Public access level
bsw@734: -- ------------------------------------------------------------------------
bsw@813: -- Available options:
bsw@1667: -- "none" (default)
bsw@813: -- -> Closed user group, no public access at all
bsw@813: -- (except login/registration/password reset)
bsw@813: -- "anonymous"
bsw@813: -- -> Shows only initiative/suggestions texts and aggregated
bsw@813: -- supporter/voter counts
bsw@813: -- "authors_pseudonymous"
bsw@813: -- -> Like anonymous, but shows screen names of authors
bsw@813: -- "all_pseudonymous"
bsw@813: -- -> Show everything a member can see, except profile pages
bsw@813: -- "everything"
bsw@813: -- -> Show everything a member can see, including profile pages
bsw@813: -- ------------------------------------------------------------------------
bsw@1667: -- config.public_access = "none"
bsw@731:
bsw@729: -- List of enabled languages, defaults to available languages
bsw@730: -- ------------------------------------------------------------------------
bsw@1129: -- config.enabled_languages = { 'en', 'de', 'eo', 'el', 'hu', 'it', 'ka', 'nl', 'zh-Hans', 'zh-TW' }
bsw@2:
bsw@729: -- Default language, defaults to "en"
bsw@730: -- ------------------------------------------------------------------------
bsw@729: -- config.default_lang = "en"
poelzi@163:
bsw@1656: -- Disable registration
bsw@1656: -- ------------------------------------------------------------------------
bsw@1656: -- Available options:
bsw@1656: -- false: registration is enabled (default)
bsw@1656: -- true: registration is disabled
bsw@1656: -- ------------------------------------------------------------------------
bsw@1656: -- config.disable_registration = true
bsw@1656:
bsw@1656: -- A HTML formatted text the user has to accept while registering
bsw@1656: -- ------------------------------------------------------------------------
bsw@1656: -- config.use_terms = "
Insert terms here
" bsw@1656: bsw@1656: -- Checkbox(es) the user has to accept while registering bsw@1656: -- ------------------------------------------------------------------------ bsw@1656: -- config.use_terms_checkboxes = { bsw@1656: -- { bsw@1656: -- name = "terms_of_use_v1", bsw@1656: -- html = "I accept the terms of use.", bsw@1656: -- not_accepted_error = "You have to accept the terms of use to be able to register." bsw@1656: -- }, bsw@1656: -- { bsw@1656: -- name = "extra_terms_of_use_v1", bsw@1656: -- html = "I accept the extra terms of use.", bsw@1656: -- not_accepted_error = "You have to accept the extra terms of use to be able to register." bsw@1656: -- } bsw@1656: -- } bsw@1656: bsw@734: -- after how long is a user considered inactive and the trustee will see warning, bsw@734: -- notation is according to postgresql intervals, default: no warning at all bsw@730: -- ------------------------------------------------------------------------ bsw@729: -- config.delegation_warning_time = '6 months' bsw/jbe@6: bsw@988: -- after which time a user is advised (_soft) or forced (_hard) to check bsw@988: -- unit and area delegations. default: no check at all bsw@988: -- ------------------------------------------------------------------------ bsw@1656: -- config.check_delegations_interval_soft = "3 months" bsw@988: -- config.check_delegations_interval_hard = "6 months" bsw@988: bsw@988: -- default option when checking delegations bsw@988: -- available options: "confirm", "revoke" and "none", default: "confirm" bsw@988: -- ------------------------------------------------------------------------ bsw@988: -- config.check_delegations_default = "confirm" bsw@988: bsw@734: -- Prefix of all automatic mails, defaults to "[Liquid Feedback] " bsw@730: -- ------------------------------------------------------------------------ bsw@729: -- config.mail_subject_prefix = "[LiquidFeedback] " bsw@734: bsw@734: -- Sender of all automatic mails, defaults to system defaults bsw@734: -- ------------------------------------------------------------------------ bsw@839: -- config.mail_envelope_from = "liquidfeedback@example.com" bsw@839: -- config.mail_from = { name = "LiquidFeedback", address = "liquidfeedback@example.com" } bsw@839: -- config.mail_reply_to = { name = "Support", address = "support@example.com" } bsw/jbe@6: bsw@1250: -- Template for digest emails bsw@1250: -- #{name} will be replaced by member screen name bsw@1250: -- #{digest} will be replaced with the digest content bsw@1250: -- ------------------------------------------------------------------------ bsw@1250: -- config.notification_digest_template = [[ bsw@1250: -- Hello #{name}, bsw@1250: -- bsw@1250: -- this is your personal digest. bsw@1250: -- bsw@1250: -- #{digest} bsw@1250: -- ]] bsw@1250: bsw@905: -- Configuration of password hashing algorithm (defaults to "crypt_sha512") bsw@905: -- ------------------------------------------------------------------------ bsw@905: -- config.password_hash_algorithm = "crypt_sha512" bsw@1206: -- config.password_hash_algorithm = "crypt_sha256" bsw@905: -- config.password_hash_algorithm = "crypt_md5" bsw@905: bsw@905: -- Number of rounds for crypt_sha* algorithms, minimum and maximum bsw@905: -- (defaults to minimum 10000 and maximum 20000) bsw@905: -- ------------------------------------------------------------------------ bsw@905: -- config.password_hash_min_rounds = 10000 bsw@905: -- config.password_hash_max_rounds = 20000 bsw@905: bsw@729: -- Local directory for database dumps offered for download bsw@730: -- ------------------------------------------------------------------------ bsw@729: -- config.download_dir = nil bsw@51: bsw@729: -- Special use terms for database dump download bsw@730: -- ------------------------------------------------------------------------ bsw@729: -- config.download_use_terms = "=== Download use terms ===\n" bsw/jbe@52: bsw@734: -- Use custom image conversion, defaults to ImageMagick's convert bsw@730: -- ------------------------------------------------------------------------ bsw@729: --config.member_image_content_type = "image/jpeg" bsw@729: --config.member_image_convert_func = { bsw@729: -- avatar = function(data) return extos.pfilter(data, "convert", "jpeg:-", "-thumbnail", "48x48", "jpeg:-") end, bsw@729: -- photo = function(data) return extos.pfilter(data, "convert", "jpeg:-", "-thumbnail", "240x240", "jpeg:-") end bsw@729: --} bsw@51: bsw@1656: -- Initiative attachments bsw@1656: -- ------------------------------------------------------------------------ bsw@1656: -- config.attachments = {} bsw@1656: bsw@1656: -- Conversion function for recoding attachments bsw@1656: -- ------------------------------------------------------------------------ bsw@1656: -- config.attachments.convert_func = function(data) bsw@1656: -- return extos.pfilter(data, "convert", "jpeg:-", "-thumbnail", "240x240", "jpeg:-") bsw@1656: -- end bsw@1656: bsw@1656: -- Custom UI colors, defaults to green/blue bsw@1656: -- ------------------------------------------------------------------------ bsw@1656: -- config.style = { bsw@1656: -- color_md = { bsw@1656: -- primary = "green", bsw@1656: -- primary_contrast = "dark", bsw@1656: -- accent = "blue", bsw@1656: -- accent_contrast = "dark" bsw@1656: -- } bsw@1656: -- } bsw@1656: bsw@1656: -- Member profile fields, defaults to no extra fields bsw@1656: -- ------------------------------------------------------------------------ bsw@1656: -- config.member_profile_fields = {} bsw@1656: bsw@1045: -- Display a html formatted public message of the day bsw@837: -- ------------------------------------------------------------------------ bsw@1045: -- config.motd_public = "The MOTD is formatted with HTML
" bsw@1045: bsw@1045: -- Display a html formatted internal message of the day bsw@1045: -- ------------------------------------------------------------------------ bsw@1045: -- config.motd_intern = "The MOTD is formatted with HTML
" bsw@837: bsw@961: -- Free timings bsw@961: -- ------------------------------------------------------------------------ bsw@961: -- This example expects a date string entered in the free timing field bsw@961: -- by the user creating a poll, interpreting it as target date for then bsw@961: -- poll and splits the remaining time at the ratio of 4:1:2 bsw@961: -- Please note, polling policies never have an admission phase bsw@961: -- The available_func is optional, if not set any target date is allowed bsw@961: bsw@1222: --[[ bsw@961: config.free_timing = { bsw@961: calculate_func = function(policy, timing_string) bsw@1166: local function interval_by_seconds(secs) bsw@961: local secs_per_day = 60 * 60 * 24 bsw@961: local days bsw@961: days = math.floor(secs / secs_per_day) bsw@961: secs = secs - days * secs_per_day bsw@961: return days .. " days " .. secs .. " seconds" bsw@961: end bsw@961: local target_date = parse.date(timing_string, atom.date) bsw@961: if not target_date then bsw@961: return false bsw@961: end bsw@961: local target_timestamp = target_date.midday bsw@961: local now = atom.timestamp:get_current() bsw@961: trace.debug(target_timestamp, now) bsw@961: local duration = target_timestamp - now bsw@961: if duration < 0 then bsw@961: return false bsw@961: end bsw@961: return { bsw@961: discussion = interval_by_seconds(duration / 7 * 4), bsw@961: verification = interval_by_seconds(duration / 7 * 1), bsw@961: voting = interval_by_seconds(duration / 7 * 2) bsw@961: } bsw@961: end, bsw@961: available_func = function(policy) bsw@961: return { bsw@961: { name = "End of 2013", id = '2013-12-31' }, bsw@961: { name = "End of 2014", id = '2014-12-31' }, bsw@961: { name = "End of 2015", id = '2015-12-31' } bsw@961: } bsw@961: end bsw@961: } bsw@1222: --]] bsw@1170: bsw@1209: -- External references bsw@1209: -- ------------------------------------------------------------------------ bsw@1209: -- Rendering of external references bsw@1209: bsw@1209: --[[ bsw@1209: config.render_external_reference = { bsw@1209: draft = function(draft, wrapper) bsw@1209: wrapper(function() bsw@1209: ui.tag{ content = draft.external_reference) bsw@1209: end) bsw@1209: end, bsw@1209: initiative = function(initiative, wrapper) bsw@1209: wrapper(function() bsw@1209: ui.tag{ content = initiative.external_reference) bsw@1209: end) bsw@1209: end bsw@1209: end bsw@1209: --]] bsw@1209: bsw@1656: -- Configuration of OAuth2 service, defaults to OAuth2 disabled bsw@1656: -- ------------------------------------------------------------------------ bsw@1656: -- config.oauth2 = {} bsw@1656: bsw@1656: -- Additional scopes bsw@1656: -- config.oauth2.available_scopes = { bsw@1656: -- { scope = "privA", name = { de = "Beispielprivileg A", en = "Example privilege A" } }, bsw@1656: -- { scope = "privB", name = { de = "Beispielprivileg B", en = "Example privilege B" } } bsw@1656: -- } bsw@1656: bsw@1656: -- OAuth2 endpoint magic string for dynamic app registration bsw@1656: -- ------------------------------------------------------------------------ bsw@1656: -- config.oauth2.endpoint_magic = "liquidfeedback_client_redirection_endpoint" bsw@1656: bsw@1656: -- OAuth2 Token lifetime and timings bsw@1656: -- ------------------------------------------------------------------------ bsw@1656: -- config.oauth2.authorization_code_lifetime = 5 * 60 bsw@1656: -- config.oauth2.refresh_token_lifetime = 60 * 60 * 24 * 30 * 3 bsw@1656: -- config.oauth2.refresh_pause = 60 bsw@1656: -- config.oauth2.refresh_grace_period = 60 bsw@1656: -- config.oauth2.access_token_lifetime = 60 * 60 bsw@1656: bsw@1106: -- Admin logger bsw@1106: -- ------------------------------------------------------------------------ bsw@1106: -- Logging administrative activities bsw@1106: -- disabled by default bsw@1106: bsw@1656: -- config.admin_logger = function(params) bsw@1656: -- local adminid = app.session.member_id bsw@1656: -- local adminname = app.session.member.name bsw@1656: -- local url = params._webmcp_path bsw@1656: -- -- do something (e.g. calling 'logger' via extos.pfilter) bsw@1656: -- end bsw@1106: bsw@1170: -- Application server fork configuration bsw@1170: -- ------------------------------------------------------------------------ bsw@1170: -- config.fork = { bsw@1170: -- pre = 2, -- desired number of spare (idle) processes bsw@1170: -- min = 4, -- minimum number of processes bsw@1170: -- max = 128, -- maximum number of processes (hard limit) bsw@1170: -- delay = 0.125, -- delay (seconds) between creation of spare processes bsw@1170: -- error_delay = 2, -- delay (seconds) before retry of failed process creation bsw@1170: -- exit_delay = 2, -- delay (seconds) between destruction of excessive spare processes bsw@1170: -- idle_timeout = 900, -- idle time (seconds) after a fork gets terminated (0 for no timeout) bsw@1170: -- memory_limit = 0, -- maximum memory consumption (bytes) before process gets terminated bsw@1170: -- min_requests = 50, -- minimum count of requests handled before fork is terminated bsw@1170: -- max_requests = 100 -- maximum count of requests handled before fork is terminated bsw@1170: -- } bsw@1170: bsw@1170: -- HTTP server options bsw@1170: -- ------------------------------------------------------------------------ bsw@1170: -- http_options = { bsw@1170: -- static_headers = {} -- string or table of static headers to be returned with every request bsw@1170: -- request_header_size_limit = 1024*1024, -- maximum size of request body sent by client bsw@1170: -- request_body_size_limit = 64*1024*1024, -- maximum size of request body sent by client jbe@1198: -- idle_timeout = 65, -- maximum time until receiving the first byte of the request headera jbe@1198: -- stall_timeout = 60, -- maximum time a client connection may be stalled jbe@1198: -- request_header_timeout = 120, -- maximum time until receiving the remaining bytes of the request header jbe@1198: -- response_timeout = 3600, -- time in which request body and response must be sent bsw@1170: -- maximum_input_chunk_size = 16384 -- tweaks behavior of request-body parser bsw@1170: -- minimum_output_chunk_size = 1024 -- chunk size for chunked-transfer-encoding bsw@1170: -- } bsw@1170: bsw@729: -- WebMCP accelerator jbe@1223: -- ------------------------------------------------------------------------ jbe@1223: -- uncomment the following line to use C implementations of chosen jbe@1223: -- functions: bsw@730: -- ------------------------------------------------------------------------ bsw@729: -- require 'webmcp_accelerator' jbe@1223: bsw@868: -- Trace debug bsw@1222: -- ------------------------------------------------------------------------ bsw@868: -- uncomment the following line to enable debug trace jbe@1223: -- ------------------------------------------------------------------------ bsw@1656: -- config.enable_debug_trace = true bsw@1656: bsw@1656: -- Configuration of lf4rcs, disabled by default bsw@1656: -- for example configration see _lf4rcs.lua bsw@1656: -- ------------------------------------------------------------------------ bsw@1656: -- execute.config("_lf4rcs") bsw@1656: bsw@1656: -- Configuration of ldap authentication, disabled by default bsw@1656: -- for example configration, see _ldap.lua bsw@1656: -- for active directory example, see _ldap_ad.lua bsw@1656: -- ------------------------------------------------------------------------ bsw@1656: -- execute.config("_ldap") bsw@1656: -- execute.config("_ldap_ad") bsw/jbe@1309: bsw@1656: -- Integration of Etherpad, disabled by default bsw@1656: -- ------------------------------------------------------------------------ bsw@1656: --config.etherpad = { bsw@1656: -- base_url = "http://example.com:9001/", bsw@1656: -- api_base = "http://localhost:9001/", bsw@1656: -- api_key = "mysecretapikey", bsw@1656: -- group_id = "mygroupname", bsw@1656: -- cookie_path = "/" bsw@1656: --} bsw/jbe@0: bsw@1656: -- Integration of FirstLife bsw@1656: -- ------------------------------------------------------------------------ bsw@1656: --[[ bsw@1656: config.firstlife = { bsw@1656: coordinates = "", bsw@1656: areaviewer_url = "about:blank", bsw@1656: inputmap_url = "about:blank" bsw/jbe@1309: } bsw@1656: config.allow_new_draft_callback = true bsw@1656: --]] bsw/jbe@1309: