@mesh-tech/mesh-cli 0.40.14 → 0.41.0
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/bin/{mesh.auth-preflight-BGI5LPLN.js → mesh.auth-preflight-JTUNS42O.js} +1 -1
- package/dist/bin/{mesh.chunk-3WJGDNHA.js → mesh.chunk-HB2IZKLP.js} +5 -5
- package/dist/bin/{mesh.chunk-4XX62O6Z.js → mesh.chunk-HC7V75J3.js} +1 -1
- package/dist/bin/{mesh.chunk-GLG5JBI7.js → mesh.chunk-IZLAJATU.js} +61 -34
- package/dist/bin/mesh.chunk-IZLAJATU.js.map +6 -0
- package/dist/bin/{mesh.chunk-O5CP4NPZ.js → mesh.chunk-LAUSCBV6.js} +2 -2
- package/dist/bin/{mesh.chunk-WT27GBE4.js → mesh.chunk-M57BJLLK.js} +1 -1
- package/dist/bin/{mesh.chunk-YKW256CK.js → mesh.chunk-PANTMVC3.js} +3 -3
- package/dist/bin/{mesh.chunk-2QIVBQX5.js.map → mesh.chunk-PL3P54MY.js.map} +1 -1
- package/dist/bin/{mesh.chunk-EHLBX24J.js → mesh.chunk-QUKWWFZI.js} +1 -1
- package/dist/bin/{mesh.chunk-DYWR76EO.js → mesh.chunk-TYM27CO3.js} +1 -1
- package/dist/bin/{mesh.chunk-O677AU5E.js → mesh.chunk-YB4VOTA7.js} +1 -1
- package/dist/bin/{mesh.convert-7N2H2SVK.js → mesh.convert-4BZC5PYA.js} +1 -1
- package/dist/bin/{mesh.create-app-GQIGCZNI.js → mesh.create-app-3HYMOLXT.js} +4 -4
- package/dist/bin/{mesh.dev-token-server-IJUVRBWI.js → mesh.dev-token-server-4N6HGQAF.js} +3 -3
- package/dist/bin/mesh.js +10 -10
- package/dist/bin/{mesh.login-N5LPLRRX.js → mesh.login-Q6R5GMVM.js} +3 -3
- package/dist/bin/{mesh.platform-setup-PCDLE2EI.js → mesh.platform-setup-LVFHW263.js} +1 -1
- package/dist/bin/{mesh.preview-RJGTCTY3.js → mesh.preview-ALFPQCWU.js} +1 -1
- package/dist/bin/mesh.program-BZPJOWJK.js +24 -0
- package/dist/bin/{mesh.registry-5U4L6256.js → mesh.registry-KA3CNNPZ.js} +5 -5
- package/dist/bin/{mesh.registry-identity-6UPUHKO2.js → mesh.registry-identity-DSTAHXUS.js} +4 -4
- package/dist/bin/{mesh.review-command-MLBWVHF7.js → mesh.review-command-3ZXPS6Y3.js} +4 -4
- package/dist/bin/{mesh.start-24YIFB4O.js → mesh.start-XKQW5DW4.js} +2 -2
- package/dist/bin/{mesh.wizard-6HMOBC5L.js → mesh.wizard-I7HPLDDY.js} +8 -8
- package/dist/build-info.json +2 -2
- package/dist/src/commands/local/seed-hub-catalog.d.ts +4 -0
- package/dist/src/commands/local/seed-hub-catalog.js +18 -8
- package/dist/src/commands/temporal.js.map +1 -1
- package/package.json +3 -3
- package/skills/mesh/SKILL.md +1 -1
- package/templates/api-auth/api/src/schema.ts.hbs +5 -3
- package/templates/platform-repo/core/Pulumi.{{tenant}}-{{env}}.yaml.hbs +8 -0
- package/templates/platform-repo/core/index.ts +3 -0
- package/dist/bin/mesh.chunk-GLG5JBI7.js.map +0 -6
- package/dist/bin/mesh.program-WSFVQU7P.js +0 -24
- /package/dist/bin/{mesh.auth-preflight-BGI5LPLN.js.map → mesh.auth-preflight-JTUNS42O.js.map} +0 -0
- /package/dist/bin/{mesh.chunk-3WJGDNHA.js.map → mesh.chunk-HB2IZKLP.js.map} +0 -0
- /package/dist/bin/{mesh.chunk-4XX62O6Z.js.map → mesh.chunk-HC7V75J3.js.map} +0 -0
- /package/dist/bin/{mesh.chunk-O5CP4NPZ.js.map → mesh.chunk-LAUSCBV6.js.map} +0 -0
- /package/dist/bin/{mesh.chunk-WT27GBE4.js.map → mesh.chunk-M57BJLLK.js.map} +0 -0
- /package/dist/bin/{mesh.chunk-YKW256CK.js.map → mesh.chunk-PANTMVC3.js.map} +0 -0
- /package/dist/bin/{mesh.chunk-2QIVBQX5.js → mesh.chunk-PL3P54MY.js} +0 -0
- /package/dist/bin/{mesh.chunk-EHLBX24J.js.map → mesh.chunk-QUKWWFZI.js.map} +0 -0
- /package/dist/bin/{mesh.chunk-DYWR76EO.js.map → mesh.chunk-TYM27CO3.js.map} +0 -0
- /package/dist/bin/{mesh.chunk-O677AU5E.js.map → mesh.chunk-YB4VOTA7.js.map} +0 -0
- /package/dist/bin/{mesh.convert-7N2H2SVK.js.map → mesh.convert-4BZC5PYA.js.map} +0 -0
- /package/dist/bin/{mesh.create-app-GQIGCZNI.js.map → mesh.create-app-3HYMOLXT.js.map} +0 -0
- /package/dist/bin/{mesh.dev-token-server-IJUVRBWI.js.map → mesh.dev-token-server-4N6HGQAF.js.map} +0 -0
- /package/dist/bin/{mesh.login-N5LPLRRX.js.map → mesh.login-Q6R5GMVM.js.map} +0 -0
- /package/dist/bin/{mesh.platform-setup-PCDLE2EI.js.map → mesh.platform-setup-LVFHW263.js.map} +0 -0
- /package/dist/bin/{mesh.preview-RJGTCTY3.js.map → mesh.preview-ALFPQCWU.js.map} +0 -0
- /package/dist/bin/{mesh.program-WSFVQU7P.js.map → mesh.program-BZPJOWJK.js.map} +0 -0
- /package/dist/bin/{mesh.registry-5U4L6256.js.map → mesh.registry-KA3CNNPZ.js.map} +0 -0
- /package/dist/bin/{mesh.registry-identity-6UPUHKO2.js.map → mesh.registry-identity-DSTAHXUS.js.map} +0 -0
- /package/dist/bin/{mesh.review-command-MLBWVHF7.js.map → mesh.review-command-3ZXPS6Y3.js.map} +0 -0
- /package/dist/bin/{mesh.start-24YIFB4O.js.map → mesh.start-XKQW5DW4.js.map} +0 -0
- /package/dist/bin/{mesh.wizard-6HMOBC5L.js.map → mesh.wizard-I7HPLDDY.js.map} +0 -0
|
@@ -1051,7 +1051,7 @@ async function cliReferenceStaleness(repoRoot) {
|
|
|
1051
1051
|
{ createProgram },
|
|
1052
1052
|
{ extractCliReference, renderCliReferenceMarkdown }
|
|
1053
1053
|
] = await Promise.all([
|
|
1054
|
-
import("./mesh.program-
|
|
1054
|
+
import("./mesh.program-BZPJOWJK.js"),
|
|
1055
1055
|
import("./mesh.cli-reference-H3TOPIET.js")
|
|
1056
1056
|
]);
|
|
1057
1057
|
const outPath = path3.join(repoRoot, "docs/portal/generated/cli-reference.md");
|
|
@@ -13,14 +13,14 @@ import {
|
|
|
13
13
|
resolveAppDir,
|
|
14
14
|
shouldBootstrapAppsRepo,
|
|
15
15
|
workspaceGlobForApp
|
|
16
|
-
} from "./mesh.chunk-
|
|
16
|
+
} from "./mesh.chunk-LAUSCBV6.js";
|
|
17
17
|
import "./mesh.chunk-F4654EPX.js";
|
|
18
|
-
import "./mesh.chunk-
|
|
19
|
-
import "./mesh.chunk-
|
|
18
|
+
import "./mesh.chunk-HB2IZKLP.js";
|
|
19
|
+
import "./mesh.chunk-PL3P54MY.js";
|
|
20
20
|
import "./mesh.chunk-MCBMHWXP.js";
|
|
21
21
|
import "./mesh.chunk-WFFDF346.js";
|
|
22
22
|
import "./mesh.chunk-IQOBTL42.js";
|
|
23
|
-
import "./mesh.chunk-
|
|
23
|
+
import "./mesh.chunk-HC7V75J3.js";
|
|
24
24
|
export {
|
|
25
25
|
NO_REGISTRY_ACCESS_MESSAGE,
|
|
26
26
|
PLATFORM_MONOREPO_NAME,
|
|
@@ -2,15 +2,15 @@ import {
|
|
|
2
2
|
decodeJwtPayload,
|
|
3
3
|
getValidToken,
|
|
4
4
|
readCredentials
|
|
5
|
-
} from "./mesh.chunk-
|
|
6
|
-
import "./mesh.chunk-
|
|
5
|
+
} from "./mesh.chunk-HB2IZKLP.js";
|
|
6
|
+
import "./mesh.chunk-PL3P54MY.js";
|
|
7
7
|
import "./mesh.chunk-MCBMHWXP.js";
|
|
8
8
|
import {
|
|
9
9
|
logInfo,
|
|
10
10
|
logWarn
|
|
11
11
|
} from "./mesh.chunk-WFFDF346.js";
|
|
12
12
|
import "./mesh.chunk-IQOBTL42.js";
|
|
13
|
-
import "./mesh.chunk-
|
|
13
|
+
import "./mesh.chunk-HC7V75J3.js";
|
|
14
14
|
|
|
15
15
|
// packages/mesh-cli/src/commands/dev-token-server.ts
|
|
16
16
|
import * as http from "node:http";
|
package/dist/bin/mesh.js
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
createProgram
|
|
4
|
-
} from "./mesh.chunk-
|
|
5
|
-
import "./mesh.chunk-
|
|
4
|
+
} from "./mesh.chunk-IZLAJATU.js";
|
|
5
|
+
import "./mesh.chunk-QUKWWFZI.js";
|
|
6
6
|
import {
|
|
7
7
|
formatVersionLine,
|
|
8
8
|
resolveCliRuntime
|
|
9
|
-
} from "./mesh.chunk-
|
|
10
|
-
import "./mesh.chunk-
|
|
11
|
-
import "./mesh.chunk-
|
|
12
|
-
import "./mesh.chunk-
|
|
9
|
+
} from "./mesh.chunk-YB4VOTA7.js";
|
|
10
|
+
import "./mesh.chunk-LAUSCBV6.js";
|
|
11
|
+
import "./mesh.chunk-M57BJLLK.js";
|
|
12
|
+
import "./mesh.chunk-PANTMVC3.js";
|
|
13
13
|
import "./mesh.chunk-F4654EPX.js";
|
|
14
|
-
import "./mesh.chunk-
|
|
15
|
-
import "./mesh.chunk-
|
|
16
|
-
import "./mesh.chunk-
|
|
14
|
+
import "./mesh.chunk-TYM27CO3.js";
|
|
15
|
+
import "./mesh.chunk-HB2IZKLP.js";
|
|
16
|
+
import "./mesh.chunk-PL3P54MY.js";
|
|
17
17
|
import "./mesh.chunk-MCBMHWXP.js";
|
|
18
18
|
import "./mesh.chunk-WFFDF346.js";
|
|
19
19
|
import {
|
|
20
20
|
handleCliError
|
|
21
21
|
} from "./mesh.chunk-IQOBTL42.js";
|
|
22
|
-
import "./mesh.chunk-
|
|
22
|
+
import "./mesh.chunk-HC7V75J3.js";
|
|
23
23
|
import "./mesh.chunk-OW5EMVG5.js";
|
|
24
24
|
|
|
25
25
|
// packages/mesh-cli/bin/mesh.ts
|
|
@@ -40,12 +40,12 @@ import {
|
|
|
40
40
|
tokenStillValid,
|
|
41
41
|
withDiscoveredFields,
|
|
42
42
|
writeContextConfig
|
|
43
|
-
} from "./mesh.chunk-
|
|
44
|
-
import "./mesh.chunk-
|
|
43
|
+
} from "./mesh.chunk-HB2IZKLP.js";
|
|
44
|
+
import "./mesh.chunk-PL3P54MY.js";
|
|
45
45
|
import "./mesh.chunk-MCBMHWXP.js";
|
|
46
46
|
import "./mesh.chunk-WFFDF346.js";
|
|
47
47
|
import "./mesh.chunk-IQOBTL42.js";
|
|
48
|
-
import "./mesh.chunk-
|
|
48
|
+
import "./mesh.chunk-HC7V75J3.js";
|
|
49
49
|
export {
|
|
50
50
|
CONFIG_DIR,
|
|
51
51
|
CONFIG_FILE,
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import {
|
|
2
|
+
CLI_DESCRIPTION,
|
|
3
|
+
CLI_NAME,
|
|
4
|
+
createProgram
|
|
5
|
+
} from "./mesh.chunk-IZLAJATU.js";
|
|
6
|
+
import "./mesh.chunk-QUKWWFZI.js";
|
|
7
|
+
import "./mesh.chunk-YB4VOTA7.js";
|
|
8
|
+
import "./mesh.chunk-LAUSCBV6.js";
|
|
9
|
+
import "./mesh.chunk-M57BJLLK.js";
|
|
10
|
+
import "./mesh.chunk-PANTMVC3.js";
|
|
11
|
+
import "./mesh.chunk-F4654EPX.js";
|
|
12
|
+
import "./mesh.chunk-TYM27CO3.js";
|
|
13
|
+
import "./mesh.chunk-HB2IZKLP.js";
|
|
14
|
+
import "./mesh.chunk-PL3P54MY.js";
|
|
15
|
+
import "./mesh.chunk-MCBMHWXP.js";
|
|
16
|
+
import "./mesh.chunk-WFFDF346.js";
|
|
17
|
+
import "./mesh.chunk-IQOBTL42.js";
|
|
18
|
+
import "./mesh.chunk-HC7V75J3.js";
|
|
19
|
+
import "./mesh.chunk-OW5EMVG5.js";
|
|
20
|
+
export {
|
|
21
|
+
CLI_DESCRIPTION,
|
|
22
|
+
CLI_NAME,
|
|
23
|
+
createProgram
|
|
24
|
+
};
|
|
@@ -17,14 +17,14 @@ import {
|
|
|
17
17
|
runRegistryStatus,
|
|
18
18
|
shouldRemintAfter,
|
|
19
19
|
shouldRepairUserNpmrc
|
|
20
|
-
} from "./mesh.chunk-
|
|
21
|
-
import "./mesh.chunk-
|
|
22
|
-
import "./mesh.chunk-
|
|
23
|
-
import "./mesh.chunk-
|
|
20
|
+
} from "./mesh.chunk-PANTMVC3.js";
|
|
21
|
+
import "./mesh.chunk-TYM27CO3.js";
|
|
22
|
+
import "./mesh.chunk-HB2IZKLP.js";
|
|
23
|
+
import "./mesh.chunk-PL3P54MY.js";
|
|
24
24
|
import "./mesh.chunk-MCBMHWXP.js";
|
|
25
25
|
import "./mesh.chunk-WFFDF346.js";
|
|
26
26
|
import "./mesh.chunk-IQOBTL42.js";
|
|
27
|
-
import "./mesh.chunk-
|
|
27
|
+
import "./mesh.chunk-HC7V75J3.js";
|
|
28
28
|
export {
|
|
29
29
|
CONTEXT_IGNORED_NOTICE,
|
|
30
30
|
NOT_AUTHORIZED_RERUN,
|
|
@@ -15,13 +15,13 @@ import {
|
|
|
15
15
|
registrySessionCandidates,
|
|
16
16
|
registryTokenRoles,
|
|
17
17
|
resolveRegistryIdentity
|
|
18
|
-
} from "./mesh.chunk-
|
|
19
|
-
import "./mesh.chunk-
|
|
20
|
-
import "./mesh.chunk-
|
|
18
|
+
} from "./mesh.chunk-TYM27CO3.js";
|
|
19
|
+
import "./mesh.chunk-HB2IZKLP.js";
|
|
20
|
+
import "./mesh.chunk-PL3P54MY.js";
|
|
21
21
|
import "./mesh.chunk-MCBMHWXP.js";
|
|
22
22
|
import "./mesh.chunk-WFFDF346.js";
|
|
23
23
|
import "./mesh.chunk-IQOBTL42.js";
|
|
24
|
-
import "./mesh.chunk-
|
|
24
|
+
import "./mesh.chunk-HC7V75J3.js";
|
|
25
25
|
export {
|
|
26
26
|
REGISTRY_ALIAS,
|
|
27
27
|
REGISTRY_CREDENTIAL_KEY,
|
|
@@ -10,15 +10,15 @@ import {
|
|
|
10
10
|
discoverStackExternalServices,
|
|
11
11
|
ensureAwsCredentialsForStack,
|
|
12
12
|
resolveExternalServiceScope
|
|
13
|
-
} from "./mesh.chunk-
|
|
14
|
-
import "./mesh.chunk-
|
|
15
|
-
import "./mesh.chunk-
|
|
13
|
+
} from "./mesh.chunk-QUKWWFZI.js";
|
|
14
|
+
import "./mesh.chunk-HB2IZKLP.js";
|
|
15
|
+
import "./mesh.chunk-PL3P54MY.js";
|
|
16
16
|
import "./mesh.chunk-MCBMHWXP.js";
|
|
17
17
|
import {
|
|
18
18
|
logInfo
|
|
19
19
|
} from "./mesh.chunk-WFFDF346.js";
|
|
20
20
|
import "./mesh.chunk-IQOBTL42.js";
|
|
21
|
-
import "./mesh.chunk-
|
|
21
|
+
import "./mesh.chunk-HC7V75J3.js";
|
|
22
22
|
|
|
23
23
|
// packages/mesh-cli/src/commands/mcp/review-command.ts
|
|
24
24
|
import { SSMClient } from "@aws-sdk/client-ssm";
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
reportAssembly,
|
|
5
5
|
resolveCliRuntime,
|
|
6
6
|
runAssemble
|
|
7
|
-
} from "./mesh.chunk-
|
|
7
|
+
} from "./mesh.chunk-YB4VOTA7.js";
|
|
8
8
|
import {
|
|
9
9
|
logError,
|
|
10
10
|
logInfo,
|
|
@@ -13,7 +13,7 @@ import {
|
|
|
13
13
|
import {
|
|
14
14
|
homeNpmrcPath,
|
|
15
15
|
parseNpmrcRegistryAuth
|
|
16
|
-
} from "./mesh.chunk-
|
|
16
|
+
} from "./mesh.chunk-HC7V75J3.js";
|
|
17
17
|
|
|
18
18
|
// packages/mesh-cli/src/docs/start.ts
|
|
19
19
|
import { execFileSync as execFileSync2 } from "node:child_process";
|
|
@@ -2,24 +2,24 @@ import {
|
|
|
2
2
|
bootstrapAppsRepo,
|
|
3
3
|
isInsidePlatformMonorepo,
|
|
4
4
|
shouldBootstrapAppsRepo
|
|
5
|
-
} from "./mesh.chunk-
|
|
5
|
+
} from "./mesh.chunk-LAUSCBV6.js";
|
|
6
6
|
import {
|
|
7
7
|
PLATFORM_SETUP_DEFAULTS,
|
|
8
8
|
ensureStateBucket,
|
|
9
9
|
renderPlatformNextSteps,
|
|
10
10
|
resolvePlatformSetup,
|
|
11
11
|
scaffoldPlatformRepo
|
|
12
|
-
} from "./mesh.chunk-
|
|
12
|
+
} from "./mesh.chunk-M57BJLLK.js";
|
|
13
13
|
import {
|
|
14
14
|
RegistryNotAuthorizedError
|
|
15
|
-
} from "./mesh.chunk-
|
|
15
|
+
} from "./mesh.chunk-PANTMVC3.js";
|
|
16
16
|
import {
|
|
17
17
|
resolveTargetRoot,
|
|
18
18
|
syncSkills
|
|
19
19
|
} from "./mesh.chunk-F4654EPX.js";
|
|
20
20
|
import {
|
|
21
21
|
readRegistrySession
|
|
22
|
-
} from "./mesh.chunk-
|
|
22
|
+
} from "./mesh.chunk-TYM27CO3.js";
|
|
23
23
|
import {
|
|
24
24
|
detectLocalTenant,
|
|
25
25
|
discoverConfigForContext,
|
|
@@ -31,8 +31,8 @@ import {
|
|
|
31
31
|
runLoginFlow,
|
|
32
32
|
tokenStillValid,
|
|
33
33
|
writeMeshJson
|
|
34
|
-
} from "./mesh.chunk-
|
|
35
|
-
import "./mesh.chunk-
|
|
34
|
+
} from "./mesh.chunk-HB2IZKLP.js";
|
|
35
|
+
import "./mesh.chunk-PL3P54MY.js";
|
|
36
36
|
import "./mesh.chunk-MCBMHWXP.js";
|
|
37
37
|
import {
|
|
38
38
|
logInfo,
|
|
@@ -44,7 +44,7 @@ import {
|
|
|
44
44
|
} from "./mesh.chunk-IQOBTL42.js";
|
|
45
45
|
import {
|
|
46
46
|
probeRegistryToken
|
|
47
|
-
} from "./mesh.chunk-
|
|
47
|
+
} from "./mesh.chunk-HC7V75J3.js";
|
|
48
48
|
|
|
49
49
|
// packages/mesh-cli/src/commands/init/wizard.ts
|
|
50
50
|
import * as fs from "fs";
|
|
@@ -157,7 +157,7 @@ var registryStep = {
|
|
|
157
157
|
try {
|
|
158
158
|
logInfo(REGISTRY_WHY);
|
|
159
159
|
const login = ctx.seams?.runRegistryLogin ?? (async (opts) => {
|
|
160
|
-
const { runRegistryLogin } = await import("./mesh.registry-
|
|
160
|
+
const { runRegistryLogin } = await import("./mesh.registry-KA3CNNPZ.js");
|
|
161
161
|
await runRegistryLogin(void 0, opts);
|
|
162
162
|
});
|
|
163
163
|
await login({ device: ctx.device, profile: ctx.profile });
|
package/dist/build-info.json
CHANGED
|
@@ -2,6 +2,10 @@ import type { HubCompiledAuthz } from "./hub-local.js";
|
|
|
2
2
|
export declare const HUB_AUTHZ_POINTER_PARAM = "/mesh-platform/local/dev/apps/hub/stacks/local/authz";
|
|
3
3
|
export declare const HUB_OPS_HUB_METADATA_PARAM = "/mesh-platform/local/dev/apps/hub/stacks/local/authz/ops-hub-metadata";
|
|
4
4
|
export declare function withHubCatalogRefs(pointer: Record<string, unknown>, metadataRef: string): Record<string, unknown>;
|
|
5
|
+
export declare function catalogParameters(metadata: Record<string, unknown>): Array<{
|
|
6
|
+
name: string;
|
|
7
|
+
value: string;
|
|
8
|
+
}>;
|
|
5
9
|
export declare function publishHubAuthzCatalog(compiled: HubCompiledAuthz, awsConfig: object): Promise<{
|
|
6
10
|
bundles: string[];
|
|
7
11
|
}>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { chunkSsmValue, ssmChunkPartPath } from "@mesh-tech/api-registry/ssm-chunks";
|
|
1
2
|
import { LOCAL_ENV, LOCAL_TENANT } from "./seed.js";
|
|
2
3
|
export const HUB_AUTHZ_POINTER_PARAM = `/mesh-platform/${LOCAL_TENANT}/${LOCAL_ENV}/apps/hub/stacks/local/authz`;
|
|
3
4
|
export const HUB_OPS_HUB_METADATA_PARAM = `${HUB_AUTHZ_POINTER_PARAM}/ops-hub-metadata`;
|
|
@@ -9,17 +10,26 @@ export function withHubCatalogRefs(pointer, metadataRef) {
|
|
|
9
10
|
mode: typeof pointer.mode === "string" ? pointer.mode : "policy-engine",
|
|
10
11
|
};
|
|
11
12
|
}
|
|
13
|
+
export function catalogParameters(metadata) {
|
|
14
|
+
const { value, parts } = chunkSsmValue(JSON.stringify(metadata));
|
|
15
|
+
return [
|
|
16
|
+
...parts.map((part, i) => ({ name: ssmChunkPartPath(HUB_OPS_HUB_METADATA_PARAM, i), value: part })),
|
|
17
|
+
{ name: HUB_OPS_HUB_METADATA_PARAM, value },
|
|
18
|
+
];
|
|
19
|
+
}
|
|
12
20
|
export async function publishHubAuthzCatalog(compiled, awsConfig) {
|
|
13
21
|
const { SSMClient, GetParameterCommand, PutParameterCommand } = await import("@aws-sdk/client-ssm");
|
|
14
22
|
const ssm = new SSMClient(awsConfig);
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
+
for (const { name, value } of catalogParameters(compiled.metadata)) {
|
|
24
|
+
await ssm.send(new PutParameterCommand({
|
|
25
|
+
Name: name,
|
|
26
|
+
Type: "String",
|
|
27
|
+
Tier: "Advanced",
|
|
28
|
+
Overwrite: true,
|
|
29
|
+
Value: value,
|
|
30
|
+
Description: "Hub role catalog — ops-hub-metadata (local analog of MeshHub's SpiceDBSchema export)",
|
|
31
|
+
}));
|
|
32
|
+
}
|
|
23
33
|
let current = {};
|
|
24
34
|
try {
|
|
25
35
|
const existing = await ssm.send(new GetParameterCommand({ Name: HUB_AUTHZ_POINTER_PARAM }));
|