Scratch space for learning atproto app development
1import dotenv from 'dotenv' 2import { cleanEnv, host, num, port, str, testOnly } from 'envalid' 3 4dotenv.config() 5 6export const env = cleanEnv(process.env, { 7 NODE_ENV: str({ devDefault: testOnly('test'), choices: ['development', 'production', 'test'] }), 8 HOST: host({ devDefault: testOnly('localhost') }), 9 PORT: port({ devDefault: testOnly(3000) }), 10 PUBLIC_URL: str({ devDefault: testOnly('http://localhost:3000') }), 11 COOKIE_SECRET: str(), 12 PRIVATE_KEY_ES256_B64: str(), 13 CORS_ORIGIN: str({ devDefault: testOnly('http://localhost:3000') }), 14 COMMON_RATE_LIMIT_MAX_REQUESTS: num({ devDefault: testOnly(1000) }), 15 COMMON_RATE_LIMIT_WINDOW_MS: num({ devDefault: testOnly(1000) }), 16})