-
Notifications
You must be signed in to change notification settings - Fork 2
/
config.js
51 lines (47 loc) · 1.79 KB
/
config.js
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
module.exports.config = {
env: process.env.NODE_ENV || 'dev',
port: process.env.PORT || 9191,
githubAccessToken: process.env.GITHUB_ACCESS_TOKEN,
gitlabAccessToken: process.env.GITLAB_ACCESS_TOKEN,
githubWebhookSecret: process.env.GITHUB_WEBHOOK_SECRET,
gitlabWebhookSecret: process.env.GITLAB_WEBHOOK_SECRET,
orchestratorBaseUrl: process.env.ORCHESTRATOR_BASE_URL,
orchestratorSecret: process.env.ORCHESTRATOR_SECRET,
gitBrokerSecret: process.env.GIT_BROKER_SECRET
};
module.exports.github = {
PR_OPENED: 'opened',
PR_REOPENED: 'reopened',
PR_CLOSED: 'closed',
PR_MERGED: 'merged',
STATE_OPEN: 'open',
COMMENT_CREATED: 'created'
};
module.exports.gitlab = {
BASE_URL: process.env.GITLAB_BASE_URL,
MERGE_REQUEST: 'Merge Request Hook',
PUSH_REQUEST: 'Push Hook',
COMMENT_REQUEST: 'Note Hook',
STATE_OPENED: 'opened',
STATE_MERGED: 'merged',
STATE_PUSHED: 'push',
STATE_CLOSED: 'closed'
};
module.exports.deployment = {
SPECIFIER: process.env.DEPLOYMENT_SPECIFIER || 'spaship',
ENVS_REGEX: new RegExp(/(dev|qa|stage|uat)/g)
};
module.exports.status = {
APPLICATION_DEPLOYED: 'APPLICATION_DEPLOYED',
APPLICATION_DEPLOYMENT_STARTED: 'APPLICATION_DEPLOYMENT_STARTED',
APPLICATION_DEPLOYMENT_PROCESSING: 'APPLICATION_DEPLOYMENT_PROCESSING',
APPLICATION_DEPLOYMENT_FAILED: 'APPLICATION_DEPLOYMENT_FAILED',
APPLICATION_DEPLOYMENT_TIMEOUT: 'APPLICATION_DEPLOYMENT_TIMEOUT',
APPLICATION_DELETED: 'APPLICATION_DELETED',
APPLICATION_CONFIG_UPDATED: 'APPLICATION_CONFIG_UPDATED',
APPLICATION_BUILD_STARTED: 'APPLICATION_BUILD_STARTED',
APPLICATION_BUILD_FINISHED: 'APPLICATION_BUILD_FINISHED',
APPLICATION_BUILD_FAILED: 'APPLICATION_BUILD_FAILED',
APPLICATION_BUILD_TIMEOUT: 'APPLICATION_BUILD_TIMEOUT',
APPLICATION_BUILD_TERMINATED: 'APPLICATION_BUILD_TERMINATED'
};