Add example .env var, fix linting

This commit is contained in:
Bruno Bernardino
2025-01-11 07:14:02 +00:00
parent 8929b6e7d2
commit 2a95ce06b0
2 changed files with 2 additions and 1 deletions

View File

@@ -18,3 +18,4 @@ CONFIG_ENABLED_APPS="news,notes,photos" # dashboard and files cannot be disabled
CONFIG_FILES_ROOT_PATH="data-files" CONFIG_FILES_ROOT_PATH="data-files"
CONFIG_ENABLE_EMAILS="false" # if true, email verification will be required for signups (using Brevo) CONFIG_ENABLE_EMAILS="false" # if true, email verification will be required for signups (using Brevo)
CONFIG_ENABLE_FOREVER_SIGNUP="true" # if true, all signups become active for 100 years CONFIG_ENABLE_FOREVER_SIGNUP="true" # if true, all signups become active for 100 years
# CONFIG_ALLOWED_COOKIE_DOMAINS="example.com,example.net" # can be set to allow more than the BASE_URL's domain for session cookies

View File

@@ -22,7 +22,7 @@ export function isAppEnabled(app: 'news' | 'notes' | 'photos') {
export function isCookieDomainAllowed(domain: string) { export function isCookieDomainAllowed(domain: string) {
const allowedDomains = (Deno.env.get('CONFIG_ALLOWED_COOKIE_DOMAINS') || '').split(',') as typeof domain[]; const allowedDomains = (Deno.env.get('CONFIG_ALLOWED_COOKIE_DOMAINS') || '').split(',') as typeof domain[];
if (allowedDomains.length === 0) { if (allowedDomains.length === 0) {
return true; return true;
} }