Download apps/server/src/configuration.ts from fukeke/rss: direct link, hf CLI and curl.
- Browser
- Download file 939 Bytes
-
https://huggingface.co/spaces/fukeke/rss/resolve/main/apps/server/src/configuration.ts
- Command line
-
hf download hf://spaces/fukeke/rss/apps/server/src/configuration.ts
-
curl -L -o configuration.ts https://huggingface.co/spaces/fukeke/rss/resolve/main/apps/server/src/configuration.ts
939 Bytes
| const configuration = () => { | |
| const isProd = process.env.NODE_ENV === 'production'; | |
| const port = process.env.PORT || 4000; | |
| const host = process.env.HOST || '0.0.0.0'; | |
| const maxRequestPerMinute = parseInt( | |
| `${process.env.MAX_REQUEST_PER_MINUTE}|| 60`, | |
| ); | |
| const authCode = process.env.AUTH_CODE; | |
| const platformUrl = process.env.PLATFORM_URL || 'https://weread.111965.xyz'; | |
| const originUrl = process.env.SERVER_ORIGIN_URL || ''; | |
| const feedMode = process.env.FEED_MODE as 'fulltext' | ''; | |
| const databaseType = process.env.DATABASE_TYPE || 'mysql'; | |
| return { | |
| server: { isProd, port, host }, | |
| throttler: { maxRequestPerMinute }, | |
| auth: { code: authCode }, | |
| platform: { url: platformUrl }, | |
| feed: { | |
| originUrl, | |
| mode: feedMode, | |
| }, | |
| database: { | |
| type: databaseType, | |
| }, | |
| }; | |
| }; | |
| export default configuration; | |
| export type ConfigurationType = ReturnType<typeof configuration>; | |