module.exports = { //mongodb connection string dbURL: 'mongodb://username:password@localhost:27017', //redis connection info redis: { host: '127.0.0.1', port: '6379', password: 'long random string' }, //backend webserver port port: 7000, //secrets/salts for various things sessionSecret: 'long random string', tripcodeSecret: 'long random string', ipHashSecret: 'long random string', postPasswordSecret: 'long random string', //enable secure cookies, only use with https secureCookies: true, //check referrer to prevent some CSRF attack refererCheck: true, refererRegex: '^https?:\\/\\/(?:www\\.)?domain\\.com\\/', //data used in opengraph meta tags. used to generate link previews in e.g. discord, twitter, etc meta: { siteName: 'imageboard', url: 'https://domain.com' }, //cache templates in memory. disable only if editing templates and doing dev work cacheTemplates: true, //max wait time in ms for obtaining locks for saving files lockWait: 3000, //prune modlogs older than 30 days. pruning occurs when new modlog entries are generated pruneModlogs: true, //let all users create new boards enableUserBoards: true, //extension for thumbnails. png is larger but allows transparency thumbExtension: '.png', //max thumb dimensions (square) in px thumbSize: 200, //default ban duration in ms if ban duration field is left blank defaultBanDuration: 31536000000, //max number of quotes that will be linked in a post. 0 for unlimited quoteLimit: 15, //options for code block highlighting in posts highlightOptions: { //subset of languages to allow. languageSubset: [ 'javascript', 'js', 'typescript', 'java', 'kotlin', 'php', 'c++', 'c', 'h', 'csharp', 'bash', 'sh', 'zsh', 'python', 'ruby', 'css', 'html', 'json', 'golang', 'rust' ], //threshold below which auto language is ignored threshold: 5 }, //global limits for board settings globalLimits: { threadLimit: { min: 10, max: 200 }, replyLimit: { min: 10, max: 500 }, postFiles: { max: 3 }, postFilesSize: { max: 10485760 }, bannerFiles: { max: 10 }, bannerFilesSize: { max: 10485760 }, messageLength: { max: 4000 } }, //default board settings when a board is created boardDefaults: { theme: 'lain', codeTheme: 'ir-black', sfw: false, locked: false, unlisted: false, captchaMode: 0, tphTrigger: 0, pphTrigger: 0, triggerAction: 0, forceAnon: false, early404: true, ids: false, flags: false, userPostDelete: true, userPostSpoiler: true, userPostUnlink: true, threadLimit: 200, replyLimit: 500, maxFiles: 1, forceReplyMessage: false, forceReplyFile: false, forceThreadMessage: false, forceThreadFile: false, forceThreadSubject: false, minThreadMessageLength: 0, minReplyMessageLength: 0, defaultName: 'Anon', filters: [], filterMode: 0, filterBanDuration: 0, announcement: { raw: null, markdown: null }, allowedFileTypes: { animatedImage: true, image: true, video: true, audio: true } } }