@ts-cloud/core 0.2.25 → 0.2.26
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.
- package/dist/types.d.ts +28 -0
- package/package.json +2 -2
package/dist/types.d.ts
CHANGED
|
@@ -1583,6 +1583,34 @@ export interface ComputeProxyConfig {
|
|
|
1583
1583
|
onDemandTls?: boolean;
|
|
1584
1584
|
/** Contact email for the ACME account when {@link onDemandTls} is enabled. */
|
|
1585
1585
|
onDemandTlsEmail?: string;
|
|
1586
|
+
/**
|
|
1587
|
+
* Put a CDN (CloudFront) in front of this self-hosted gateway. A CDN custom
|
|
1588
|
+
* origin can't be a bare IP and can't be one of the public aliases (it would
|
|
1589
|
+
* resolve back to the CDN — an infinite loop), so it needs a dedicated origin
|
|
1590
|
+
* hostname pointing at this box. Requests then flow
|
|
1591
|
+
* `viewer → CDN → originDomain (this box)`.
|
|
1592
|
+
*
|
|
1593
|
+
* When {@link CdnFrontConfig.secret} is set, the CDN injects it as a header
|
|
1594
|
+
* on the origin hop and the gateway rejects any request to the fronted hosts
|
|
1595
|
+
* that lacks it — so the publicly-resolvable origin can't be used to bypass
|
|
1596
|
+
* the CDN (origin lockdown via rpx `createOriginGuard`). Pair with
|
|
1597
|
+
* `buildCloudFrontOriginConfig` for the matching AWS distribution config.
|
|
1598
|
+
*/
|
|
1599
|
+
cdn?: CdnFrontConfig;
|
|
1600
|
+
}
|
|
1601
|
+
/** CDN-in-front-of-gateway configuration (see {@link ComputeProxyConfig.cdn}). */
|
|
1602
|
+
export interface CdnFrontConfig {
|
|
1603
|
+
/**
|
|
1604
|
+
* Hostname the CDN connects to (e.g. `origin.example.com`). MUST resolve to
|
|
1605
|
+
* this box and MUST NOT be one of {@link frontedHosts} (else the CDN loops).
|
|
1606
|
+
*/
|
|
1607
|
+
originDomain: string;
|
|
1608
|
+
/** Public hosts served through the CDN (its aliases) — locked down when {@link secret} is set. */
|
|
1609
|
+
frontedHosts: string[];
|
|
1610
|
+
/** Shared secret the CDN injects on the origin hop; the gateway enforces it on {@link frontedHosts}. */
|
|
1611
|
+
secret?: string;
|
|
1612
|
+
/** Header name carrying {@link secret}. @default 'X-Origin-Verify' */
|
|
1613
|
+
secretHeader?: string;
|
|
1586
1614
|
}
|
|
1587
1615
|
export interface DatabaseItemConfig {
|
|
1588
1616
|
engine?: 'dynamodb' | 'postgres' | 'mysql';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ts-cloud/core",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.26",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Core CloudFormation generation library for ts-cloud",
|
|
6
6
|
"author": "Chris Breuer <chris@stacksjs.com>",
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
"typecheck": "tsc --noEmit"
|
|
32
32
|
},
|
|
33
33
|
"dependencies": {
|
|
34
|
-
"@ts-cloud/aws-types": "0.2.
|
|
34
|
+
"@ts-cloud/aws-types": "0.2.26"
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
37
|
"typescript": "^5.9.3"
|