-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathssm-parameter-paths.ts
81 lines (76 loc) · 3 KB
/
ssm-parameter-paths.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
export interface SsmParameterPath {
path: string;
description: string;
optional?: boolean;
// Recommended naming convention for target resource, such as an S3 bucket.
// $account is substituted as the account name.
namingPattern?: string;
}
interface NamedSsmParameterPaths {
Anghammarad: SsmParameterPath;
LoggingStreamName: SsmParameterPath;
DistributionBucket: SsmParameterPath;
AccessLoggingBucket: SsmParameterPath;
ConfigurationBucket: SsmParameterPath;
PrimaryVpcId: SsmParameterPath;
PrimaryVpcPrivateSubnets: SsmParameterPath;
PrimaryVpcPublicSubnets: SsmParameterPath;
FastlyCustomerId: SsmParameterPath;
OrganisationDistributionBucket: SsmParameterPath;
DeployToolsAccountId: SsmParameterPath;
}
export const VPC_SSM_PARAMETER_PREFIX = "/account/vpc";
export const NAMED_SSM_PARAMETER_PATHS: NamedSsmParameterPaths = {
Anghammarad: {
path: "/account/services/anghammarad.topic.arn",
description: "SSM parameter containing the ARN of the Anghammarad SNS topic",
optional: true,
},
LoggingStreamName: {
path: "/account/services/logging.stream.name",
description: "SSM parameter containing the Name (not ARN) on the kinesis stream",
},
DistributionBucket: {
path: "/account/services/artifact.bucket",
description: "SSM parameter containing the S3 bucket name holding distribution artifacts",
namingPattern: "com-gu-$account-artifacts",
},
AccessLoggingBucket: {
path: "/account/services/access-logging/bucket",
description: "S3 bucket to store your access logs",
},
ConfigurationBucket: {
path: "/account/services/private.config.bucket",
description: "SSM parameter containing the S3 bucket name holding the app's private configuration",
namingPattern: "com-gu-$account-configs",
},
PrimaryVpcId: {
path: `${VPC_SSM_PARAMETER_PREFIX}/primary/id`,
description: "Virtual Private Cloud to run EC2 instances within. Should NOT be the account default VPC.",
},
PrimaryVpcPrivateSubnets: {
path: `${VPC_SSM_PARAMETER_PREFIX}/primary/subnets/private`,
description: "A comma-separated list of private subnets",
},
PrimaryVpcPublicSubnets: {
path: `${VPC_SSM_PARAMETER_PREFIX}/primary/subnets/public`,
description: "A comma-separated list of public subnets",
},
OrganisationDistributionBucket: {
path: "/organisation/services/artifact.bucket",
description: "SSM parameter containing the S3 bucket name holding organisation-level DevX artifacts",
},
FastlyCustomerId: {
path: "/account/external/fastly/customer.id",
description:
"SSM parameter containing the Fastly Customer ID. Can be obtained from https://manage.fastly.com/account/company by an admin",
optional: true,
},
DeployToolsAccountId: {
path: "/organisation/accounts/deployTools",
description: "Account ID of the Deploy Tools account. Useful as some shared resources live here.",
},
};
export const ALL_SSM_PARAMETER_PATHS: SsmParameterPath[] = Object.values(
NAMED_SSM_PARAMETER_PATHS,
) as SsmParameterPath[];