@mstuercke/pulumi-modules 0.0.16 → 0.0.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ComponentResource } from '@pulumi/pulumi';
|
|
2
|
-
import {
|
|
2
|
+
import { Project, ProjectIpAccessList, ServerlessInstance } from '@pulumi/mongodbatlas';
|
|
3
3
|
export class MongoDBCustomInstance extends ComponentResource {
|
|
4
4
|
mongoProjectId;
|
|
5
5
|
connectionString;
|
|
@@ -18,16 +18,15 @@ export class MongoDBCustomInstance extends ComponentResource {
|
|
|
18
18
|
projectId: mongoProject.id,
|
|
19
19
|
cidrBlock: '0.0.0.0/0',
|
|
20
20
|
}, { parent: this });
|
|
21
|
-
const mongoInstance = new
|
|
21
|
+
const mongoInstance = new ServerlessInstance('database', {
|
|
22
22
|
projectId: mongoProject.id,
|
|
23
23
|
name: `${projectId}-${environmentName}`,
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
},
|
|
24
|
+
providerSettingsBackingProviderName: 'AWS',
|
|
25
|
+
providerSettingsProviderName: 'SERVERLESS',
|
|
26
|
+
providerSettingsRegionName: 'EU_WEST_1', // Ireland
|
|
28
27
|
}, { parent: this });
|
|
29
28
|
this.mongoProjectId = mongoProject.id;
|
|
30
|
-
this.connectionString = mongoInstance.
|
|
29
|
+
this.connectionString = mongoInstance.connectionStringsStandardSrv;
|
|
31
30
|
this.databaseName = `${projectId}-${environmentName}`;
|
|
32
31
|
}
|
|
33
32
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ComponentResource, output } from '@pulumi/pulumi';
|
|
2
|
-
import {
|
|
2
|
+
import { getProject, getServerlessInstance } from '@pulumi/mongodbatlas';
|
|
3
3
|
export class MongoDBDefaultInstance extends ComponentResource {
|
|
4
4
|
mongoProjectId;
|
|
5
5
|
connectionString;
|
|
@@ -8,12 +8,12 @@ export class MongoDBDefaultInstance extends ComponentResource {
|
|
|
8
8
|
const { projectId, environmentName } = args;
|
|
9
9
|
super('mstuercke:mongodb:MongoDBDefaultInstance', name, undefined, opts);
|
|
10
10
|
const mongoProject = output(getProject({ name: 'default' }));
|
|
11
|
-
const mongoInstance = mongoProject.id.apply((mongoProjectId) => output(
|
|
11
|
+
const mongoInstance = mongoProject.id.apply((mongoProjectId) => output(getServerlessInstance({
|
|
12
12
|
projectId: mongoProjectId,
|
|
13
13
|
name: 'default',
|
|
14
14
|
})));
|
|
15
15
|
this.mongoProjectId = mongoProject.id;
|
|
16
|
-
this.connectionString = mongoInstance.
|
|
16
|
+
this.connectionString = mongoInstance.connectionStringsStandardSrv;
|
|
17
17
|
this.databaseName = `${projectId}-${environmentName}`;
|
|
18
18
|
}
|
|
19
19
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ComponentResource
|
|
1
|
+
import { ComponentResource } from '@pulumi/pulumi';
|
|
2
2
|
import { Api, ApiMapping, Deployment, DomainName, Integration, IntegrationResponse, Route, Stage, } from '@pulumi/aws/apigatewayv2';
|
|
3
3
|
import { Policy, Role } from '@pulumi/aws/iam';
|
|
4
4
|
import { Record } from '@pulumi/aws/route53';
|