-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.ts
131 lines (127 loc) · 3.16 KB
/
index.ts
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
/**
* Possible account environments
*/
export enum AccountEnvironment {
DEVELOPMENT = 'Development',
STAGE = 'Stage',
TEST = 'Test',
ACCEPTANCE_TEST = 'AcceptanceTest',
SYSTEM_TEST = 'SystemTest',
PRODUCTION = 'Production',
OPS = 'Ops',
ALL = 'ALL'
}
/**
* Available Service Level Agreements
*/
export enum ServiceLevelAgreement {
/**
* Monday-Friday 07:00-17:00 CET
*/
WEEKDAY = 'Weekday',
/**
* 24/7
*/
TWENTY_FOUR_SEVEN = '24/7'
}
/**
* Available ways to deploy/manage resources
*/
export enum ManagedBy {
/**
* Deployed via CloudFormation
*/
CLOUDFORMATION = 'cloudformation',
/**
* Deployed via the AWS CDK
*/
CDK = 'cdk',
/**
* Created via HashiCorp Terraform
*/
TERRAFORM = 'terraform',
/**
* Created by AWS Lambda
*/
LAMBDA = 'lambda',
/**
* Created via script (AWS CLI or AWS SDK)
*/
SCRIPT = 'script',
/**
* Manually created in the AWS Console
*/
CONSOLE = 'console'
}
/**
* Standard tags which should be applied to all resources in an Enfo account
*/
export type StackTags = {
[key: string]: string
} & {
/**
* Email of assigned owner
*/
readonly Owner: string
/**
* Name of the customer, from an Enfo perspective. This is optional if the whole account belongs to the same customer.
*/
readonly Customer?: string
/**
* Name of the project
*/
readonly Project: string
/**
* Project identifier in JIRA
*/
readonly ProjectKey: string
/**
* Cost center or business unit identification information, which is relevant for cost allocation purposes.
* Format of value is customer specific. Multiple values can be specified if there are multiple levels in a hierarchy for cost allocation.
* First value then is the top level and the following levels further down in the hierarchy.
*/
readonly CostCenter: string
/**
* Issue in JIRA which was the reason for this resource to be set up or created.
* For example KEY-123
*/
readonly SetupRequest: string
/**
* The AWS account number
*/
readonly Account: string
/**
* Name of environment that this resource belongs to.
* If it belongs to multiple environments multiple values may be specified.
* Multiple values are specified as a string with comma separation between environments. For example 'Development,Test'
*/
readonly Environment: AccountEnvironment | string
/**
* Name of the resource, which may be added for extra description.
* Do not include any key metadata in the Name tag only, use separate tags for that!
* The Name tag shall never be required to obtain key information about a resource.
* The primary purpose is to provide an easy human readable identifier.
*/
readonly Name?: string
/**
* How was this resource created and how does one manage it
* Hard set to 'cdk' for this Interface
*/
readonly ManagedBy: ManagedBy
/**
* The repo containing the mechanism defined in ManagedBy.
*/
readonly Repo?: string
/**
* The commit hash used for the deploy
*/
readonly Commit?: string
/**
* Service level agreement
*/
readonly SLA: ServiceLevelAgreement
/**
* ISO-8601
*/
readonly LastUpdated?: string
}