-
-
Notifications
You must be signed in to change notification settings - Fork 85
Expand file tree
/
Copy pathnitro.config.ts
More file actions
37 lines (37 loc) · 1.08 KB
/
nitro.config.ts
File metadata and controls
37 lines (37 loc) · 1.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
import { config } from 'dotenv';
config();
import { version } from './server/utils/config';
//https://nitro.unjs.io/config
export default defineNitroConfig({
srcDir: 'server',
compatibilityDate: '2025-03-05',
experimental: {
asyncContext: true,
tasks: true,
},
scheduledTasks: {
// Daily cron jobs (midnight)
'0 0 * * *': ['jobs:clear-metrics:daily'],
// Weekly cron jobs (Sunday midnight)
'0 0 * * 0': ['jobs:clear-metrics:weekly'],
// Monthly cron jobs (1st of month at midnight)
'0 0 1 * *': ['jobs:clear-metrics:monthly']
},
runtimeConfig: {
public: {
meta: {
name: process.env.META_NAME || '',
description: process.env.META_DESCRIPTION || '',
version: version || '',
captcha: (process.env.CAPTCHA === 'true').toString(),
captchaClientKey: process.env.CAPTCHA_CLIENT_KEY || '',
},
},
cryptoSecret: process.env.CRYPTO_SECRET,
tmdbApiKey: process.env.TMDB_API_KEY,
trakt: {
clientId: process.env.TRAKT_CLIENT_ID,
clientSecret: process.env.TRAKT_SECRET_ID,
},
},
});