~jan0sch/smederee
Showing details for patch 25ab895498360559f5049619ec205e41e5ef701b.
diff -rN -u old-smederee/modules/hub/src/main/resources/reference.conf new-smederee/modules/hub/src/main/resources/reference.conf --- old-smederee/modules/hub/src/main/resources/reference.conf 2025-01-16 10:01:31.909757881 +0000 +++ new-smederee/modules/hub/src/main/resources/reference.conf 2025-01-16 10:01:31.909757881 +0000 @@ -7,162 +7,162 @@ # Defaults are given except for password and can also be overridden via # environment variables. database { - # The class name of the JDBC driver to be used. - driver = "org.postgresql.Driver" - driver = ${?SMEDEREE_HUB_DB_DRIVER} - # The JDBC connection URL **without** username and password. - url = "jdbc:postgresql://localhost:5432/smederee" - url = ${?SMEDEREE_HUB_DB_URL} - # The username (login) needed to authenticate against the database. - user = "smederee_hub" - user = ${?SMEDEREE_HUB_DB_USER} - # The password needed to authenticate against the database. - pass = ${?SMEDEREE_HUB_DB_PASS} + # The class name of the JDBC driver to be used. + driver = "org.postgresql.Driver" + driver = ${?SMEDEREE_HUB_DB_DRIVER} + # The JDBC connection URL **without** username and password. + url = "jdbc:postgresql://localhost:5432/smederee" + url = ${?SMEDEREE_HUB_DB_URL} + # The username (login) needed to authenticate against the database. + user = "smederee_hub" + user = ${?SMEDEREE_HUB_DB_USER} + # The password needed to authenticate against the database. + pass = ${?SMEDEREE_HUB_DB_PASS} } # The general service configuration. # Settings which toggle something on or off are booleans (true / false). service { - # The hostname on which the service shall listen for requests. - host = "localhost" - # The TCP port number on which the service shall listen for requests. - port = 8080 - # A directory into which files are written that are supposed to be downloaded by users (e.g. distribution - # files of repositories). - download-directory = /var/tmp/smederee/download - download-directory = ${?SMEDEREE_DOWNLOAD_DIR} - # A file which contains the key used to build the CSRF protection. - # If it does not exist then it should be created with sensible permissions. - csrf-key-file = /var/tmp/smederee/csrf-key.bin - csrf-key-file = ${?SMEDEREE_CSRF_KEY_FILE} - # The maximum allowed size of a file in bytes to be displayed / rendered via the web interface. - render-maximum-file-size = 131072 - - # Settings affecting how the service will communicate several information to - # the "outside world" e.g. if it runs behind a reverse proxy. - external { - # The official hostname of the service which will be used for the CSRF - # protection, generation of links in e-mails etc. - host = ${hub.service.host} - - # A possible path prefix that will be prepended to any paths used in link - # generation. If no path prefix is used then you MUST either comment it out - # or set it to `path = null`! - #path = null - - # The port number which defaults to the port the service is listening on. - # Please note that this is also relevant for CSRF protection! - # If the service is running behind a reverse proxy on a standard port e.g. - # 80 or 443 (http or https) then you MUST set this either to `port = null` - # or comment it out! - port = ${hub.service.port} - - # The URL scheme which is used for links and will also determine if cookies - # will have the secure flag enabled. - # Valid options are: - # - http - # - https - scheme = "http" - } - - # Authentication / login settings - authentication { - enabled = true - - # The secret used for the cookie encryption and validation. - # Using the default should produce a warning message on startup. - cookie-secret = "CHANGEME" - - # Determines after how many failed login attempts an account gets locked. - lock-after = 5 - - # Timeouts for the authentication session. - timeouts { - # The maximum allowed age an authentication session. This setting will - # affect the invalidation of a session on the server side. - # This timeout MUST be triggered regardless of session activity. - absolute-timeout = 3 days - - # This timeout defines how long after the last activity a session will - # remain valid. - idle-timeout = 30 minutes - - # The time after which a session will be renewed (a new session ID will be - # generated). - renewal-timeout = 20 minutes - } - } - - # Billing / payment related settings - billing { - enabled = false - - # Settings for the Stripe API used for billing. - stripe { - api-key = ${?STRIPE_API_KEY} - secret-key = ${?STRIPE_SECRET_KEY} - } - } - - # Configuration for the darcs module for vcs related operations via darcs. - darcs { - # The directory used to store the actual repositories structured after owner. - # ``` - # repositories-directory - # \_ user1 - # \_ repo1 - # \_ repo2 - # \_ user2 - # \_ repo1 - # ``` - repositories-directory = /srv/smederee/darcs - repositories-directory = ${?SMEDEREE_DARCS_REPOS_DIR} - # The path to the darcs binary executable. If not a full path (i.e. just - # `darcs`) it must be present on the `$PATH` of the environment under which - # the server is running. - executable = "darcs" - executable = ${?SMEDEREE_DARCS_EXECUTABLE} - } - - # The email middleware configuration for sending email messages. - email { - # The hostname of the email server (SMTP) to connect to. - host = "localhost" - host = ${?EMAIL_HOST} - # The port number to be used for the connection. - # This is usually 25 for local sendmail connections and 465 for SMTPS or 587 SMTP_TLS connections. - port = 25 - port = ${?EMAIL_PORT} - # Specify the transport method (security) to be used for the connection (should either be SMTPS or TLS). - transport = "PLAIN" - transport = ${?EMAIL_TRANSPORT} - # An optional username if authentication is required. - username = ${?EMAIL_USERNAME} - # An optional password if authentication is required. - password = ${?EMAIL_PASSWORD} - } - - # SSH server component settings - ssh { - enabled = false - # A username for generic access to services for darcs clone, pull and push - # (e.g. `darcs pull genericUser@smederee-domain:accountName/repository`). - generic-user = "darcs" - # The hostname/address the SSH server will bind to. - host = "localhost" - host = ${?SSH_SERVER_HOST} - # The port number on which the SSH server will listen. - port = 30983 - port = ${?SSH_SERVER_PORT} - # A path to the file from which the server key is loaded and also written to if it needs to be generated. - # This file should only be accessible for the user account that runs the smederee service. - server-key-file = /var/db/smederee/server.key - server-key-file = ${?SSH_SERVER_KEY} - } - - # Signup / registration related settings. - signup { - enabled = true - } + # The hostname on which the service shall listen for requests. + host = "localhost" + # The TCP port number on which the service shall listen for requests. + port = 8080 + # A directory into which files are written that are supposed to be downloaded by users (e.g. distribution + # files of repositories). + download-directory = /var/tmp/smederee/download + download-directory = ${?SMEDEREE_DOWNLOAD_DIR} + # A file which contains the key used to build the CSRF protection. + # If it does not exist then it should be created with sensible permissions. + csrf-key-file = /var/tmp/smederee/csrf-key.bin + csrf-key-file = ${?SMEDEREE_CSRF_KEY_FILE} + # The maximum allowed size of a file in bytes to be displayed / rendered via the web interface. + render-maximum-file-size = 131072 + + # Settings affecting how the service will communicate several information to + # the "outside world" e.g. if it runs behind a reverse proxy. + external { + # The official hostname of the service which will be used for the CSRF + # protection, generation of links in e-mails etc. + host = ${hub.service.host} + + # A possible path prefix that will be prepended to any paths used in link + # generation. If no path prefix is used then you MUST either comment it out + # or set it to `path = null`! + #path = null + + # The port number which defaults to the port the service is listening on. + # Please note that this is also relevant for CSRF protection! + # If the service is running behind a reverse proxy on a standard port e.g. + # 80 or 443 (http or https) then you MUST set this either to `port = null` + # or comment it out! + port = ${hub.service.port} + + # The URL scheme which is used for links and will also determine if cookies + # will have the secure flag enabled. + # Valid options are: + # - http + # - https + scheme = "http" + } + + # Authentication / login settings + authentication { + enabled = true + + # The secret used for the cookie encryption and validation. + # Using the default should produce a warning message on startup. + cookie-secret = "CHANGEME" + + # Determines after how many failed login attempts an account gets locked. + lock-after = 5 + + # Timeouts for the authentication session. + timeouts { + # The maximum allowed age an authentication session. This setting will + # affect the invalidation of a session on the server side. + # This timeout MUST be triggered regardless of session activity. + absolute-timeout = 3 days + + # This timeout defines how long after the last activity a session will + # remain valid. + idle-timeout = 30 minutes + + # The time after which a session will be renewed (a new session ID will be + # generated). + renewal-timeout = 20 minutes + } + } + + # Billing / payment related settings + billing { + enabled = false + + # Settings for the Stripe API used for billing. + stripe { + api-key = ${?STRIPE_API_KEY} + secret-key = ${?STRIPE_SECRET_KEY} + } + } + + # Configuration for the darcs module for vcs related operations via darcs. + darcs { + # The directory used to store the actual repositories structured after owner. + # ``` + # repositories-directory + # \_ user1 + # \_ repo1 + # \_ repo2 + # \_ user2 + # \_ repo1 + # ``` + repositories-directory = /srv/smederee/darcs + repositories-directory = ${?SMEDEREE_DARCS_REPOS_DIR} + # The path to the darcs binary executable. If not a full path (i.e. just + # `darcs`) it must be present on the `$PATH` of the environment under which + # the server is running. + executable = "darcs" + executable = ${?SMEDEREE_DARCS_EXECUTABLE} + } + + # The email middleware configuration for sending email messages. + email { + # The hostname of the email server (SMTP) to connect to. + host = "localhost" + host = ${?EMAIL_HOST} + # The port number to be used for the connection. + # This is usually 25 for local sendmail connections and 465 for SMTPS or 587 SMTP_TLS connections. + port = 25 + port = ${?EMAIL_PORT} + # Specify the transport method (security) to be used for the connection (should either be SMTPS or TLS). + transport = "PLAIN" + transport = ${?EMAIL_TRANSPORT} + # An optional username if authentication is required. + username = ${?EMAIL_USERNAME} + # An optional password if authentication is required. + password = ${?EMAIL_PASSWORD} + } + + # SSH server component settings + ssh { + enabled = false + # A username for generic access to services for darcs clone, pull and push + # (e.g. `darcs pull genericUser@smederee-domain:accountName/repository`). + generic-user = "darcs" + # The hostname/address the SSH server will bind to. + host = "localhost" + host = ${?SSH_SERVER_HOST} + # The port number on which the SSH server will listen. + port = 30983 + port = ${?SSH_SERVER_PORT} + # A path to the file from which the server key is loaded and also written to if it needs to be generated. + # This file should only be accessible for the user account that runs the smederee service. + server-key-file = /var/db/smederee/server.key + server-key-file = ${?SSH_SERVER_KEY} + } + + # Signup / registration related settings. + signup { + enabled = true + } } }