-
Notifications
You must be signed in to change notification settings - Fork 182
Expand file tree
/
Copy pathvalidators.ts
More file actions
21 lines (20 loc) · 999 Bytes
/
validators.ts
File metadata and controls
21 lines (20 loc) · 999 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
import dotenv from 'dotenv'
import { cleanEnv, num, str } from 'envalid'
// Load environment variables from .env file
dotenv.config()
export const operatorEnv = cleanEnv(process.env, {
GIT_ORG: str({ desc: 'Git organisation', default: 'otomi' }),
GIT_REPO: str({ desc: 'Git repository', default: 'values' }),
GITOPS_MANIFESTS_NS_PATH: str({
desc: 'Path to the gitops manifests namespace',
default: 'env/manifests/namespaces',
}),
GITOPS_MANIFESTS_GLOBAL_PATH: str({
desc: 'Path to the gitops manifests global',
default: 'env/manifests/global',
}),
POLL_INTERVAL_MS: num({ desc: 'Interval in which the operator polls Git', default: 1000 }),
RECONCILE_INTERVAL_MS: num({ desc: 'Interval in which the operator reconciles the cluster in', default: 300_000 }),
INSTALL_RETRIES: num({ desc: 'Number of installation retry attempts', default: 1000 }),
INSTALL_MAX_TIMEOUT_MS: num({ desc: 'Maximum timeout for installation retries in milliseconds', default: 10000 }),
})