blob: b36b6224ff4ee6bb7b40f025f6c9ed7ad4a2accc [file] [log] [blame]
Copybara botbe50d492023-11-30 00:16:42 +01001<?php
Adrià Vilanova Martínez5af86512023-12-02 20:44:16 +01002/*
3 * hores
4 * Copyright (c) 2023 Adrià Vilanova Martínez
5 *
6 * This program is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU Affero General Public License as
8 * published by the Free Software Foundation, either version 3 of the
9 * License, or (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU Affero General Public License for more details.
15 *
16 * You should have received a copy of the GNU Affero General Public
17 * License along with this program.
18 * If not, see http://www.gnu.org/licenses/.
19 */
20
Copybara botbe50d492023-11-30 00:16:42 +010021$conf = [];
22$conf["db"] = [];
23$conf["db"]["user"] = ""; // Enter the MySQL username
24$conf["db"]["password"] = ""; // Enter the MySQL password
25$conf["db"]["database"] = ""; // Enter the MySQL database name
26$conf["db"]["host"] = ""; // Enter the MySQL host
27
28$conf["path"] = ""; // Enter the absolute path to the website
29$conf["fullPath"] = ""; // Enter the URI pointing to the website
30$conf["appName"] = "Registro horario"; // Enter the name of the website
31$conf["passwordLen"] = 10; // Password length for the automatically generated passwords
32$conf["enableWorkerUI"] = true; // Allows workers to sign in in order to view their incidents and schedule, and enter new incidents (which will go to the moderation queue)
33$conf["attachmentsFolder"] = ""; // Folder where incident attachments will be saved, with a slash at the end (ex: "/home/user/files/")
34$conf["backgroundColor"] = "green"; // Background color of the website (hex or mdl color)
35$conf["backgroundColorIsDark"] = false; // Whether the background color is dark
36$conf["logo"] = ""; // Optional, set it to a URL of a logo which will be displayed in the nav bar.
37$conf["enableRecovery"] = false; // Sets whether users can recover passwords.
38$conf["debug"] = false; // Sets whether the app shows debug information useful to the developer. WARNING: DO NOT ENABLE IN PRODUCTION AS IT MAY SHOW SENSITIVE INFORMATION
Adrià Vilanova Martínezb81f2862023-12-20 23:49:57 +010039$conf["superdebug"] = false; // Sets whether to enable super debug mode (for now it only disables redirects, displays verbose errors when calling security::checkParams() and throws an ErrorException whenever the severity is included in |error_reporting()|)
Copybara botbe50d492023-11-30 00:16:42 +010040
41$conf["pdfs"] = [];
42$conf["pdfs"]["workersAlwaysHaveBreakfastAndLunch"] = false; // Sets up whether when an incident overlaps breakfast or lunch, the length of the incident should subtract lunch and breakfast time (false) or not because workers will have lunch or breakfast at another time inside of the work schedule (true). WARNING: SETTING THIS TO TRUE MAY LEAD TO UNEXPECTED RESULTS IN THE SUMMARY SHOWN AT THE BOTTOM OF DETAILED PDFs.
43$conf["pdfs"]["showExactTimeForBreakfastAndLunch"] = true; // Whether time for breakfast and lunch should be indicated with the start and end time (true) or with a summary of how many hours it consisted of (false).
44
45$conf["validation"] = [];
46$conf["validation"]["defaultMethod"] = validations::METHOD_SIMPLE; // Validation method which will be shown by default to a worker to validate incidents/records.
47$conf["validation"]["allowedMethods"] = [validations::METHOD_SIMPLE]; // Validation methods which are allowed to be used by a worker.
48$conf["validation"]["gracePeriod"] = 3; // Grace period for considering a validation as pending by some parts of the script (more info at https://avm99963.github.io/hores-external/administradores/instalacion-y-configuracion/configuracion/#notificacion-de-validaciones-pendientes)
49
50$conf["secondFactor"] = [];
51$conf["secondFactor"]["enabled"] = false; // Whether the second factor is allowed to be used
52$conf["secondFactor"]["origin"] = ""; // Domain name where the application will be hosted (for instance, "example.org")
53
54$conf["mail"] = []; // SMTP details for the email account which sends email notifications
55$conf["mail"]["enabled"] = false; // Whether the app will send email notifications
56$conf["mail"]["smtpauth"] = true; // Whether the SMTP server should be contacted securely
57$conf["mail"]["host"] = ""; // SMTP server host
58$conf["mail"]["port"] = 587; // SMTP server port
59$conf["mail"]["username"] = ""; // Username of the email account
60$conf["mail"]["password"] = ""; // Password of the email account
61$conf["mail"]["remitent"] = ""; // Email address set as the remitent of the emails sent
62$conf["mail"]["remitentName"] = ""; // Name of the remitent
63$conf["mail"]["subjectPrefix"] = "[Registro horario]"; // Prefix which will be added to the subject of all emails
64$conf["mail"]["adminEmail"] = ""; // Email address of the site administrator
65
66$conf["mail"]["capabilities"] = []; // Individual switches for certain email notifications
67$conf["mail"]["capabilities"]["notifyOnWorkerIncidentCreation"] = true; // Notify the site administrator when a worker creates an incident
68$conf["mail"]["capabilities"]["notifyOnAdminIncidentCreation"] = true; // Notify the site administrator when an admin creates an incident
69$conf["mail"]["capabilities"]["notifyCategoryResponsiblesOnIncidentCreation"] = true; // Notify category responsibles when an incident is created either by an admin or a worker (only if the incident type is configured with the 'notify' option)
70$conf["mail"]["capabilities"]["notifyWorkerOnIncidentDecision"] = true; // Notify a worker when their incident is verified to let them know if it was approved or not
71$conf["mail"]["capabilities"]["sendPendingValidationsReminder"] = true; // Notify a worker monthly if they have pending incidents or records to validate
72
73$conf["signinThrottling"] = []; // Settings for the security feature of the app which disables login when it detects unusual behaviour
74$conf["signinThrottling"]["attemptCountLimit"] = []; // Sets limits for the number of sign-in attempts made in the last 10 seconds
75$conf["signinThrottling"]["attemptCountLimit"]["global"] = 300; // Global limit for all sign-in attempts
76$conf["signinThrottling"]["attemptCountLimit"]["ip"] = 25; // Limit for the sign-in attempts made by a single IP address
77$conf["signinThrottling"]["attemptCountLimit"]["ipBlock"] = 100; // Limit for the sign-in attempts made by an IP address block
78$conf["signinThrottling"]["attemptCountLimit"]["ipBlocksPerUsername"] = 3; // Limit for the number of different ip blocks allowed to make sign-in attempts to a single user account
79$conf["signinThrottling"]["attemptCountLimit"]["username"] = 5; // Limit for the sign-in attempts willing to sign in to a single user account
80
81$conf["signinThrottling"]["retentionDays"] = 30; // Sets for how many days we should keep the records in the signinattempts table