@go-to-k/cdkd 0.101.2 → 0.102.1
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/README.md +14 -1
- package/dist/cli.js +46 -34
- package/dist/cli.js.map +1 -1
- package/dist/{deploy-engine-BzsWm3DG.js → deploy-engine-D4t--jpp.js} +14 -3
- package/dist/{deploy-engine-BzsWm3DG.js.map → deploy-engine-D4t--jpp.js.map} +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -673,7 +673,19 @@ new cdk.CfnOutput(this, 'BucketArn', {
|
|
|
673
673
|
});
|
|
674
674
|
```
|
|
675
675
|
|
|
676
|
-
After deployment, outputs are resolved and saved to the S3 state file:
|
|
676
|
+
After deployment, outputs are resolved and printed at the end of `cdkd deploy` (matching CDK CLI's format) and saved to the S3 state file:
|
|
677
|
+
|
|
678
|
+
```text
|
|
679
|
+
Deployment Summary:
|
|
680
|
+
Stack: MyStack
|
|
681
|
+
...
|
|
682
|
+
Duration: 21.25s
|
|
683
|
+
|
|
684
|
+
Outputs:
|
|
685
|
+
MyStack.BucketArn = arn:aws:s3:::actual-bucket-name-xyz
|
|
686
|
+
|
|
687
|
+
✓ Deployment completed successfully
|
|
688
|
+
```
|
|
677
689
|
|
|
678
690
|
```json
|
|
679
691
|
{
|
|
@@ -687,6 +699,7 @@ After deployment, outputs are resolved and saved to the S3 state file:
|
|
|
687
699
|
|
|
688
700
|
- CloudFormation: Outputs accessible via `aws cloudformation describe-stacks`
|
|
689
701
|
- cdkd: Outputs saved in S3 state file (e.g., `s3://bucket/cdkd/MyStack/us-east-1/state.json`)
|
|
702
|
+
- Both print outputs to stdout after a successful deploy
|
|
690
703
|
- Both resolve intrinsic functions (Ref, Fn::GetAtt, etc.) to actual values
|
|
691
704
|
|
|
692
705
|
## Exit codes
|
package/dist/cli.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { a as setAwsClients, i as resetAwsClients, r as getAwsClients, t as AwsClients } from "./aws-clients-CuHRHcyW.js";
|
|
3
|
-
import { A as resolveApp, B as CdkdError, C as AssetPublisher, D as Synthesizer, E as buildDockerImage, F as warnDeprecatedNoPrefixCliFlag, G as PartialFailureError, I as AssemblyReader, J as ResourceUpdateNotSupportedError, K as ProvisioningError, M as resolveSkipPrefix, N as resolveStateBucketWithDefault, O as getDefaultStateBucketName, P as resolveStateBucketWithDefaultAndSource, R as resolveBucketRegion, S as shouldRetainResource, T as WorkGraph, U as LocalInvokeBuildError, X as StackHasActiveImportsError, Y as RouteDiscoveryError, Z as StackTerminationProtectionError, _ as DiffCalculator, a as withRetry, at as getLogger, b as LockManager, c as collectInlinePolicyNamesManagedBySiblings, ct as getLiveRenderer, d as normalizeAwsTagsToCfn, dt as generateResourceName, f as resolveExplicitPhysicalId, ft as generateResourceNameWithFallback, g as IntrinsicFunctionResolver, h as assertRegionMatch, i as withResourceDeadline, j as resolveCaptureObservedState, k as getLegacyStateBucketName, l as CDK_PATH_TAG, lt as PATTERN_B_NAME_PROPERTIES, m as CloudControlProvider, mt as withStackName, n as DEFAULT_RESOURCE_WARN_AFTER_MS, nt as normalizeAwsError, o as IMPLICIT_DELETE_DEPENDENCIES, p as ProviderRegistry, pt as withSkipPrefix, q as ResourceTimeoutError, r as DeployEngine, rt as withErrorHandling, s as IAMRoleProvider, st as runStackBuffered, t as DEFAULT_RESOURCE_TIMEOUT_MS, u as matchesCdkPath, ut as PATTERN_B_RESOURCE_TYPES, v as DagBuilder, w as stringifyValue, x as S3StateBackend, y as TemplateParser } from "./deploy-engine-
|
|
3
|
+
import { A as resolveApp, B as CdkdError, C as AssetPublisher, D as Synthesizer, E as buildDockerImage, F as warnDeprecatedNoPrefixCliFlag, G as PartialFailureError, I as AssemblyReader, J as ResourceUpdateNotSupportedError, K as ProvisioningError, M as resolveSkipPrefix, N as resolveStateBucketWithDefault, O as getDefaultStateBucketName, P as resolveStateBucketWithDefaultAndSource, R as resolveBucketRegion, S as shouldRetainResource, T as WorkGraph, U as LocalInvokeBuildError, X as StackHasActiveImportsError, Y as RouteDiscoveryError, Z as StackTerminationProtectionError, _ as DiffCalculator, a as withRetry, at as getLogger, b as LockManager, c as collectInlinePolicyNamesManagedBySiblings, ct as getLiveRenderer, d as normalizeAwsTagsToCfn, dt as generateResourceName, f as resolveExplicitPhysicalId, ft as generateResourceNameWithFallback, g as IntrinsicFunctionResolver, h as assertRegionMatch, i as withResourceDeadline, j as resolveCaptureObservedState, k as getLegacyStateBucketName, l as CDK_PATH_TAG, lt as PATTERN_B_NAME_PROPERTIES, m as CloudControlProvider, mt as withStackName, n as DEFAULT_RESOURCE_WARN_AFTER_MS, nt as normalizeAwsError, o as IMPLICIT_DELETE_DEPENDENCIES, p as ProviderRegistry, pt as withSkipPrefix, q as ResourceTimeoutError, r as DeployEngine, rt as withErrorHandling, s as IAMRoleProvider, st as runStackBuffered, t as DEFAULT_RESOURCE_TIMEOUT_MS, u as matchesCdkPath, ut as PATTERN_B_RESOURCE_TYPES, v as DagBuilder, w as stringifyValue, x as S3StateBackend, y as TemplateParser } from "./deploy-engine-D4t--jpp.js";
|
|
4
4
|
import { createHash, createPublicKey, createVerify, randomBytes, randomUUID } from "node:crypto";
|
|
5
5
|
import { CopyObjectCommand, CreateBucketCommand, DeleteBucketAnalyticsConfigurationCommand, DeleteBucketCommand, DeleteBucketCorsCommand, DeleteBucketIntelligentTieringConfigurationCommand, DeleteBucketInventoryConfigurationCommand, DeleteBucketLifecycleCommand, DeleteBucketMetricsConfigurationCommand, DeleteBucketPolicyCommand, DeleteBucketReplicationCommand, DeleteBucketTaggingCommand, DeleteBucketWebsiteCommand, DeleteObjectCommand, DeleteObjectsCommand, GetBucketAccelerateConfigurationCommand, GetBucketCorsCommand, GetBucketEncryptionCommand, GetBucketLifecycleConfigurationCommand, GetBucketLocationCommand, GetBucketLoggingCommand, GetBucketNotificationConfigurationCommand, GetBucketPolicyCommand, GetBucketReplicationCommand, GetBucketTaggingCommand, GetBucketVersioningCommand, GetBucketWebsiteCommand, GetObjectCommand, GetObjectLockConfigurationCommand, GetPublicAccessBlockCommand, HeadBucketCommand, ListBucketAnalyticsConfigurationsCommand, ListBucketIntelligentTieringConfigurationsCommand, ListBucketInventoryConfigurationsCommand, ListBucketMetricsConfigurationsCommand, ListBucketsCommand, ListDirectoryBucketsCommand, ListObjectVersionsCommand, ListObjectsV2Command, NoSuchBucket, PutBucketAccelerateConfigurationCommand, PutBucketAnalyticsConfigurationCommand, PutBucketCorsCommand, PutBucketEncryptionCommand, PutBucketIntelligentTieringConfigurationCommand, PutBucketInventoryConfigurationCommand, PutBucketLifecycleConfigurationCommand, PutBucketLoggingCommand, PutBucketMetricsConfigurationCommand, PutBucketNotificationConfigurationCommand, PutBucketOwnershipControlsCommand, PutBucketPolicyCommand, PutBucketReplicationCommand, PutBucketTaggingCommand, PutBucketVersioningCommand, PutBucketWebsiteCommand, PutObjectCommand, PutObjectLockConfigurationCommand, PutPublicAccessBlockCommand, S3Client, S3ServiceException } from "@aws-sdk/client-s3";
|
|
6
6
|
import { AddRoleToInstanceProfileCommand, AddUserToGroupCommand, AttachGroupPolicyCommand, AttachUserPolicyCommand, CreateGroupCommand, CreateInstanceProfileCommand, CreateLoginProfileCommand, CreateUserCommand, DeleteAccessKeyCommand, DeleteGroupCommand, DeleteGroupPolicyCommand, DeleteInstanceProfileCommand, DeleteLoginProfileCommand, DeleteRolePolicyCommand, DeleteUserCommand, DeleteUserPermissionsBoundaryCommand, DeleteUserPolicyCommand, DetachGroupPolicyCommand, DetachUserPolicyCommand, GetGroupCommand, GetGroupPolicyCommand, GetInstanceProfileCommand, GetRolePolicyCommand, GetUserCommand, GetUserPolicyCommand, IAMClient, ListAccessKeysCommand, ListAttachedGroupPoliciesCommand, ListAttachedUserPoliciesCommand, ListGroupPoliciesCommand, ListGroupsForUserCommand, ListInstanceProfilesCommand, ListUserPoliciesCommand, ListUserTagsCommand, ListUsersCommand, NoSuchEntityException, PutGroupPolicyCommand, PutRolePolicyCommand, PutUserPermissionsBoundaryCommand, PutUserPolicyCommand, RemoveRoleFromInstanceProfileCommand, RemoveUserFromGroupCommand, TagUserCommand, UntagUserCommand, UpdateLoginProfileCommand } from "@aws-sdk/client-iam";
|
|
@@ -12346,9 +12346,17 @@ var ApiGatewayProvider = class ApiGatewayProvider {
|
|
|
12346
12346
|
* when CDK's `LambdaIntegration({ responseTransferMode: STREAM })` was
|
|
12347
12347
|
* used together with the streaming `response-streaming-invocations` URI.
|
|
12348
12348
|
*
|
|
12349
|
-
* `
|
|
12350
|
-
*
|
|
12351
|
-
*
|
|
12349
|
+
* `MethodResponses` and `IntegrationResponses` are applied as separate
|
|
12350
|
+
* per-entry calls (`PutMethodResponseCommand` /
|
|
12351
|
+
* `PutIntegrationResponseCommand`). Order matters: every
|
|
12352
|
+
* `MethodResponse` is put BEFORE any `IntegrationResponse`, because AWS
|
|
12353
|
+
* validates that the matching method response already exists when
|
|
12354
|
+
* accepting an integration response (the integration response's
|
|
12355
|
+
* `ResponseParameters` / `ResponseTemplates` map onto headers declared
|
|
12356
|
+
* by the method response). The inverse order surfaces as
|
|
12357
|
+
* `Invalid mapping expression specified: ... [No method response exists
|
|
12358
|
+
* for method.]` — the canonical trigger is a CORS preflight OPTIONS
|
|
12359
|
+
* method emitted by `RestApi({ defaultCorsPreflightOptions: ... })`.
|
|
12352
12360
|
*/
|
|
12353
12361
|
async createMethod(logicalId, resourceType, properties) {
|
|
12354
12362
|
this.logger.debug(`Creating API Gateway Method ${logicalId}`);
|
|
@@ -12379,27 +12387,39 @@ var ApiGatewayProvider = class ApiGatewayProvider {
|
|
|
12379
12387
|
authorizationScopes
|
|
12380
12388
|
}));
|
|
12381
12389
|
const integration = properties["Integration"];
|
|
12382
|
-
if (integration) {
|
|
12383
|
-
|
|
12390
|
+
if (integration) await this.apiGatewayClient.send(new PutIntegrationCommand({
|
|
12391
|
+
restApiId,
|
|
12392
|
+
resourceId,
|
|
12393
|
+
httpMethod,
|
|
12394
|
+
type: integration["Type"],
|
|
12395
|
+
integrationHttpMethod: integration["IntegrationHttpMethod"],
|
|
12396
|
+
uri: integration["Uri"],
|
|
12397
|
+
connectionType: integration["ConnectionType"],
|
|
12398
|
+
connectionId: integration["ConnectionId"],
|
|
12399
|
+
credentials: integration["Credentials"],
|
|
12400
|
+
requestParameters: integration["RequestParameters"],
|
|
12401
|
+
requestTemplates: integration["RequestTemplates"],
|
|
12402
|
+
passthroughBehavior: integration["PassthroughBehavior"],
|
|
12403
|
+
contentHandling: integration["ContentHandling"],
|
|
12404
|
+
timeoutInMillis: integration["TimeoutInMillis"],
|
|
12405
|
+
cacheNamespace: integration["CacheNamespace"],
|
|
12406
|
+
cacheKeyParameters: integration["CacheKeyParameters"],
|
|
12407
|
+
tlsConfig: integration["TlsConfig"] ? { insecureSkipVerification: integration["TlsConfig"]["InsecureSkipVerification"] } : void 0,
|
|
12408
|
+
responseTransferMode: integration["ResponseTransferMode"]
|
|
12409
|
+
}));
|
|
12410
|
+
const methodResponses = properties["MethodResponses"];
|
|
12411
|
+
if (methodResponses) for (const resp of methodResponses) {
|
|
12412
|
+
const statusCode = String(resp["StatusCode"]);
|
|
12413
|
+
await this.apiGatewayClient.send(new PutMethodResponseCommand({
|
|
12384
12414
|
restApiId,
|
|
12385
12415
|
resourceId,
|
|
12386
12416
|
httpMethod,
|
|
12387
|
-
|
|
12388
|
-
|
|
12389
|
-
|
|
12390
|
-
connectionType: integration["ConnectionType"],
|
|
12391
|
-
connectionId: integration["ConnectionId"],
|
|
12392
|
-
credentials: integration["Credentials"],
|
|
12393
|
-
requestParameters: integration["RequestParameters"],
|
|
12394
|
-
requestTemplates: integration["RequestTemplates"],
|
|
12395
|
-
passthroughBehavior: integration["PassthroughBehavior"],
|
|
12396
|
-
contentHandling: integration["ContentHandling"],
|
|
12397
|
-
timeoutInMillis: integration["TimeoutInMillis"],
|
|
12398
|
-
cacheNamespace: integration["CacheNamespace"],
|
|
12399
|
-
cacheKeyParameters: integration["CacheKeyParameters"],
|
|
12400
|
-
tlsConfig: integration["TlsConfig"] ? { insecureSkipVerification: integration["TlsConfig"]["InsecureSkipVerification"] } : void 0,
|
|
12401
|
-
responseTransferMode: integration["ResponseTransferMode"]
|
|
12417
|
+
statusCode,
|
|
12418
|
+
responseModels: resp["ResponseModels"],
|
|
12419
|
+
responseParameters: resp["ResponseParameters"]
|
|
12402
12420
|
}));
|
|
12421
|
+
}
|
|
12422
|
+
if (integration) {
|
|
12403
12423
|
const integrationResponses = integration["IntegrationResponses"];
|
|
12404
12424
|
if (integrationResponses) for (const ir of integrationResponses) {
|
|
12405
12425
|
const statusCode = String(ir["StatusCode"]);
|
|
@@ -12415,18 +12435,6 @@ var ApiGatewayProvider = class ApiGatewayProvider {
|
|
|
12415
12435
|
}));
|
|
12416
12436
|
}
|
|
12417
12437
|
}
|
|
12418
|
-
const methodResponses = properties["MethodResponses"];
|
|
12419
|
-
if (methodResponses) for (const resp of methodResponses) {
|
|
12420
|
-
const statusCode = String(resp["StatusCode"]);
|
|
12421
|
-
await this.apiGatewayClient.send(new PutMethodResponseCommand({
|
|
12422
|
-
restApiId,
|
|
12423
|
-
resourceId,
|
|
12424
|
-
httpMethod,
|
|
12425
|
-
statusCode,
|
|
12426
|
-
responseModels: resp["ResponseModels"],
|
|
12427
|
-
responseParameters: resp["ResponseParameters"]
|
|
12428
|
-
}));
|
|
12429
|
-
}
|
|
12430
12438
|
const physicalId = `${restApiId}|${resourceId}|${httpMethod}`;
|
|
12431
12439
|
this.logger.debug(`Successfully created API Gateway Method ${logicalId}: ${physicalId}`);
|
|
12432
12440
|
return {
|
|
@@ -28069,6 +28077,10 @@ async function deployCommand(stacks, options) {
|
|
|
28069
28077
|
logger.info(` Deleted: ${deployResult.deleted}`);
|
|
28070
28078
|
logger.info(` Unchanged: ${deployResult.unchanged}`);
|
|
28071
28079
|
logger.info(` Duration: ${(deployResult.durationMs / 1e3).toFixed(2)}s`);
|
|
28080
|
+
if (deployResult.outputs && Object.keys(deployResult.outputs).length > 0) {
|
|
28081
|
+
logger.info("\nOutputs:");
|
|
28082
|
+
for (const [key, value] of Object.entries(deployResult.outputs)) logger.info(` ${deployResult.stackName}.${key} = ${String(value)}`);
|
|
28083
|
+
}
|
|
28072
28084
|
if (options.dryRun) logger.info("\n✓ Dry run completed - no actual changes made");
|
|
28073
28085
|
else logger.info("\n✓ Deployment completed successfully");
|
|
28074
28086
|
} finally {
|
|
@@ -42697,7 +42709,7 @@ function reorderArgs(argv) {
|
|
|
42697
42709
|
*/
|
|
42698
42710
|
async function main() {
|
|
42699
42711
|
const program = new Command();
|
|
42700
|
-
program.name("cdkd").description("CDK Direct - Deploy AWS CDK apps directly via SDK/Cloud Control API").version("0.
|
|
42712
|
+
program.name("cdkd").description("CDK Direct - Deploy AWS CDK apps directly via SDK/Cloud Control API").version("0.102.1");
|
|
42701
42713
|
program.addCommand(createBootstrapCommand());
|
|
42702
42714
|
program.addCommand(createSynthCommand());
|
|
42703
42715
|
program.addCommand(createListCommand());
|