@infoxchange/make-it-so 2.12.0-internal-testing-add-ix-ses-idenity.4 → 2.12.0-internal-testing-add-ix-ses-idenity.5
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.
|
@@ -2,12 +2,9 @@ import { Construct } from "constructs";
|
|
|
2
2
|
type ConstructScope = ConstructorParameters<typeof Construct>[0];
|
|
3
3
|
type ConstructId = ConstructorParameters<typeof Construct>[1];
|
|
4
4
|
type Props = {
|
|
5
|
-
mailFromSubdomain?: string;
|
|
6
|
-
} & ({
|
|
7
5
|
domain: string;
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
});
|
|
6
|
+
mailFromSubdomain?: string;
|
|
7
|
+
};
|
|
11
8
|
export declare class IxSESIdentity extends Construct {
|
|
12
9
|
constructor(scope: ConstructScope, id: ConstructId, props: Props);
|
|
13
10
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IxSESIdentity.d.ts","sourceRoot":"","sources":["../../src/cdk-constructs/IxSESIdentity.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAKvC,KAAK,cAAc,GAAG,qBAAqB,CAAC,OAAO,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC;AACjE,KAAK,WAAW,GAAG,qBAAqB,CAAC,OAAO,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC;AAE9D,KAAK,KAAK,GAAG;IACX,
|
|
1
|
+
{"version":3,"file":"IxSESIdentity.d.ts","sourceRoot":"","sources":["../../src/cdk-constructs/IxSESIdentity.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAKvC,KAAK,cAAc,GAAG,qBAAqB,CAAC,OAAO,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC;AACjE,KAAK,WAAW,GAAG,qBAAqB,CAAC,OAAO,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC;AAE9D,KAAK,KAAK,GAAG;IACX,MAAM,EAAE,MAAM,CAAC;IACf,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B,CAAC;AAEF,qBAAa,aAAc,SAAQ,SAAS;gBAC9B,KAAK,EAAE,cAAc,EAAE,EAAE,EAAE,WAAW,EAAE,KAAK,EAAE,KAAK;CAuDjE"}
|
|
@@ -4,7 +4,9 @@ import * as ses from "aws-cdk-lib/aws-ses";
|
|
|
4
4
|
import * as cdk from "aws-cdk-lib";
|
|
5
5
|
export class IxSESIdentity extends Construct {
|
|
6
6
|
constructor(scope, id, props) {
|
|
7
|
-
const domain =
|
|
7
|
+
const domain = props.domain.includes("@")
|
|
8
|
+
? props.domain.split("@")[1]
|
|
9
|
+
: props.domain;
|
|
8
10
|
const mailFromDomain = `${props.mailFromSubdomain ?? "mail"}.${domain}`;
|
|
9
11
|
super(scope, id);
|
|
10
12
|
const identity = new ses.EmailIdentity(scope, `${id}EmailIdentity`, {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@infoxchange/make-it-so",
|
|
3
|
-
"version": "2.12.0-internal-testing-add-ix-ses-idenity.
|
|
3
|
+
"version": "2.12.0-internal-testing-add-ix-ses-idenity.5",
|
|
4
4
|
"description": "Makes deploying services to IX infra easy",
|
|
5
5
|
"repository": "github:infoxchange/make-it-so",
|
|
6
6
|
"type": "module",
|
|
@@ -7,19 +7,15 @@ type ConstructScope = ConstructorParameters<typeof Construct>[0];
|
|
|
7
7
|
type ConstructId = ConstructorParameters<typeof Construct>[1];
|
|
8
8
|
|
|
9
9
|
type Props = {
|
|
10
|
+
domain: string;
|
|
10
11
|
mailFromSubdomain?: string;
|
|
11
|
-
}
|
|
12
|
-
| {
|
|
13
|
-
domain: string;
|
|
14
|
-
}
|
|
15
|
-
| {
|
|
16
|
-
from: string;
|
|
17
|
-
}
|
|
18
|
-
);
|
|
12
|
+
};
|
|
19
13
|
|
|
20
14
|
export class IxSESIdentity extends Construct {
|
|
21
15
|
constructor(scope: ConstructScope, id: ConstructId, props: Props) {
|
|
22
|
-
const domain =
|
|
16
|
+
const domain = props.domain.includes("@")
|
|
17
|
+
? props.domain.split("@")[1]
|
|
18
|
+
: props.domain;
|
|
23
19
|
const mailFromDomain = `${props.mailFromSubdomain ?? "mail"}.${domain}`;
|
|
24
20
|
|
|
25
21
|
super(scope, id);
|