Skip to content

Commit 2e9cc9b

Browse files
authored
Merge pull request #6 from smallcase/feat/network-array
feat: changed readme
2 parents e0ca3ad + 64d0849 commit 2e9cc9b

File tree

1 file changed

+28
-23
lines changed

1 file changed

+28
-23
lines changed

README.md

Lines changed: 28 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -14,45 +14,52 @@ import { App } from '@aws-cdk/core';
1414
export class UnknownAPIStackDev extends Stack {
1515
constructor(scope: Construct, id: string, props?: StackProps) {
1616
super(scope, id, props);
17-
new MicroService(stack, 'UnknownAPI', {
18-
appName: 'UnknownAPI',
19-
env: 'development',
17+
new MicroService(this, 'test', {
18+
appName: 'test',
19+
env: 'prod',
2020
asgMaxSize: '1',
2121
asgMinSize: '1',
2222
diskSize: 20,
2323
instanceLabels: [
2424
{
25-
key: 'NODE-VERSION',
25+
key: 'SUDOERS_GROUPS_TAG',
2626
propagateAtLaunch: true,
27-
value: '12',
28-
},
29-
{
30-
key: 'TYPE',
31-
propagateAtLaunch: true,
32-
value: 'application',
27+
value: 'Developers',
3328
},
3429
],
3530
instanceType: 't3.micro',
3631
vpc: 'vpc-1234567',
37-
port: 8000,
38-
protocol: 'HTTP',
39-
healthCheckPath: '/health',
40-
subnets: ['subnet-987654321', 'subnet-12345678'],
32+
role: {
33+
type: 'existing',
34+
roleArn: 'arn:aws:iam::123456789233:instance-profile/API-DEV',
35+
},
36+
sshKey: 'master-dev',
37+
subnets: ['subnet-12345678', 'subnet-123456789'],
4138
tcpRules: [
4239
{
4340
sourceSG: 'sg-12345678',
4441
description: 'ssh rule',
4542
port: 22,
4643
},
44+
{
45+
sourceSG: 'sg-987654321',
46+
description: 'from load balancer',
47+
port: 8000,
48+
},
49+
],
50+
networkProps: [
51+
{
52+
healthCheckPath: '/health',
53+
host: 'abc-test-123.smallcase.com',
54+
lbArn: 'arn:aws:elasticloadbalancing:ap-south-1:123456789233:loadbalancer/app/API-DEV-External',
55+
sslEnabled: false,
56+
port: 8000,
57+
protocol: 'HTTP',
58+
zoneName: 'smallcase.com',
59+
zoneId: '1234567891011'
60+
},
4761
],
48-
host: 'abc-test-123.smallcase.com',
49-
lbArn: 'arn:aws:elasticloadbalancing:ap-south-1:12345678910:loadbalancer/app/API-DEV-External',
50-
sslEnabled: false,
51-
sshKey: 'master-dev',
5262
createCodedeployApplication: true,
53-
role: {
54-
type: 'new',
55-
},
5663
});
5764
}
5865
}
@@ -149,5 +156,3 @@ Deploy using
149156
```
150157
~ -> cdk deploy
151158
```
152-
153-
PS: Because of an [aws-cdk issue](https://github.com/aws/aws-cdk/issues/6803), creating a Route 53 record from existing load balancer is not possible using cdk.

0 commit comments

Comments
 (0)