@ts-cloud/core 0.7.14 → 0.7.16
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/index.js
CHANGED
|
@@ -22380,13 +22380,11 @@ function hasManagementDashboardSite(config) {
|
|
|
22380
22380
|
if (!site)
|
|
22381
22381
|
return false;
|
|
22382
22382
|
const root = site.root ?? "";
|
|
22383
|
-
return name
|
|
22383
|
+
return isManagementDashboardSiteName(name) || root === "ui/dist" || root.endsWith("/ui/dist") || root.endsWith("/dist/ui");
|
|
22384
22384
|
});
|
|
22385
22385
|
}
|
|
22386
22386
|
var MANAGEMENT_DASHBOARD_SITE_PREFIX = "dashboard-";
|
|
22387
|
-
function
|
|
22388
|
-
if (primary)
|
|
22389
|
-
return "dashboard";
|
|
22387
|
+
function managementDashboardSiteName(domain) {
|
|
22390
22388
|
return MANAGEMENT_DASHBOARD_SITE_PREFIX + domain.replace(/^dashboard\./, "").replace(/\./g, "-");
|
|
22391
22389
|
}
|
|
22392
22390
|
function isManagementDashboardSiteName(name) {
|
|
@@ -22412,11 +22410,11 @@ function resolveManagementDashboardSites(config, environment, opts) {
|
|
|
22412
22410
|
...build,
|
|
22413
22411
|
...auth2
|
|
22414
22412
|
};
|
|
22415
|
-
return [{ name:
|
|
22413
|
+
return [{ name: managementDashboardSiteName(domain), site }];
|
|
22416
22414
|
}
|
|
22417
22415
|
const domains = resolveDashboardDomains(config, environment, opts.domain);
|
|
22418
|
-
return domains.map((domain
|
|
22419
|
-
name:
|
|
22416
|
+
return domains.map((domain) => ({
|
|
22417
|
+
name: managementDashboardSiteName(domain),
|
|
22420
22418
|
site: {
|
|
22421
22419
|
root: opts.uiRoot,
|
|
22422
22420
|
deploy: "server",
|
|
@@ -47276,6 +47274,7 @@ export {
|
|
|
47276
47274
|
migrationManager,
|
|
47277
47275
|
metricsManager,
|
|
47278
47276
|
mergeInfrastructure,
|
|
47277
|
+
managementDashboardSiteName,
|
|
47279
47278
|
makeAWSRequestOnce,
|
|
47280
47279
|
makeAWSRequestAsync,
|
|
47281
47280
|
makeAWSRequest,
|
|
@@ -53,9 +53,22 @@ export declare function resolveDashboardDomain(config: Pick<CloudConfig, 'sites'
|
|
|
53
53
|
export declare function resolveDashboardDomains(config: Pick<CloudConfig, 'sites' | 'environments' | 'infrastructure'>, environment?: EnvironmentType, explicit?: string): string[];
|
|
54
54
|
/** Does the config already define the management dashboard as a site? */
|
|
55
55
|
export declare function hasManagementDashboardSite(config: Pick<CloudConfig, 'sites'>): boolean;
|
|
56
|
-
/** Prefix under which
|
|
56
|
+
/** Prefix under which every auto-injected dashboard is keyed. */
|
|
57
57
|
export declare const MANAGEMENT_DASHBOARD_SITE_PREFIX = "dashboard-";
|
|
58
|
-
/**
|
|
58
|
+
/**
|
|
59
|
+
* The site key for a dashboard on `domain`: `dashboard-<apex-dashed>` (e.g.
|
|
60
|
+
* `dashboard-chrisbreuer-me`), so each dashboard is its own service +
|
|
61
|
+
* `/var/www` dir. Every dashboard is domain-keyed — including the primary —
|
|
62
|
+
* because a bare `dashboard` key collides on a shared multi-tenant box
|
|
63
|
+
* (`attachTo`): every attaching project would ship its dashboard release to
|
|
64
|
+
* the same `/var/www/dashboard/current`, silently overwriting the others.
|
|
65
|
+
*/
|
|
66
|
+
export declare function managementDashboardSiteName(domain: string): string;
|
|
67
|
+
/**
|
|
68
|
+
* Is `name` a management-dashboard site key? Matches the domain-keyed form
|
|
69
|
+
* (`dashboard-<apex-dashed>`) plus the bare `dashboard` key, which is how
|
|
70
|
+
* hand-configured dashboards and pre-0.8 deploys are keyed.
|
|
71
|
+
*/
|
|
59
72
|
export declare function isManagementDashboardSiteName(name: string): boolean;
|
|
60
73
|
/**
|
|
61
74
|
* Build EVERY management-dashboard site to auto-inject on a server deploy — one
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ts-cloud/core",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.16",
|
|
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.7.
|
|
34
|
+
"@ts-cloud/aws-types": "0.7.16"
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
37
|
"typescript": "^7.0.2"
|