@aws-cdk/toolkit-lib 0.3.1 → 0.3.3
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 +1 -1
- package/build-info.json +2 -2
- package/db.json.gz +0 -0
- package/lib/actions/bootstrap/index.d.ts +1 -1
- package/lib/actions/bootstrap/index.js +5 -5
- package/lib/actions/deploy/index.d.ts +1 -1
- package/lib/actions/deploy/index.js +1 -1
- package/lib/actions/deploy/private/deploy-options.d.ts +1 -1
- package/lib/actions/deploy/private/deploy-options.js +1 -1
- package/lib/actions/deploy/private/helpers.d.ts +3 -2
- package/lib/actions/deploy/private/helpers.js +3 -3
- package/lib/actions/diff/private/helpers.d.ts +5 -9
- package/lib/actions/diff/private/helpers.js +6 -23
- package/lib/api/aws-auth/account-cache.d.ts +41 -0
- package/lib/api/aws-auth/account-cache.js +108 -0
- package/lib/api/aws-auth/awscli-compatible.d.ts +70 -0
- package/lib/api/aws-auth/awscli-compatible.js +250 -0
- package/lib/api/aws-auth/cached.d.ts +11 -0
- package/lib/api/aws-auth/cached.js +26 -0
- package/lib/api/aws-auth/credential-plugins.d.ts +38 -0
- package/lib/api/aws-auth/credential-plugins.js +154 -0
- package/lib/api/aws-auth/private/index.d.ts +11 -0
- package/lib/api/aws-auth/private/index.js +37 -0
- package/lib/api/aws-auth/provider-caching.d.ts +13 -0
- package/lib/api/aws-auth/provider-caching.js +24 -0
- package/lib/api/aws-auth/proxy-agent.d.ts +13 -0
- package/lib/api/aws-auth/proxy-agent.js +54 -0
- package/lib/api/aws-auth/sdk-logger.d.ts +69 -0
- package/lib/api/aws-auth/sdk-logger.js +128 -0
- package/lib/api/aws-auth/sdk-provider.d.ts +195 -0
- package/lib/api/aws-auth/sdk-provider.js +373 -0
- package/lib/api/aws-auth/sdk.d.ts +235 -0
- package/lib/api/aws-auth/sdk.js +391 -0
- package/lib/api/aws-auth/tracing.d.ts +11 -0
- package/lib/api/aws-auth/tracing.js +60 -0
- package/lib/api/aws-auth/types.d.ts +79 -1
- package/lib/api/aws-auth/types.js +74 -1
- package/lib/api/aws-auth/user-agent.d.ts +7 -0
- package/lib/api/aws-auth/user-agent.js +20 -0
- package/lib/api/aws-auth/util.d.ts +6 -0
- package/lib/api/aws-auth/util.js +21 -0
- package/lib/api/bootstrap/bootstrap-environment.d.ts +35 -0
- package/lib/api/bootstrap/bootstrap-environment.js +323 -0
- package/lib/api/bootstrap/bootstrap-props.d.ts +130 -0
- package/lib/api/bootstrap/bootstrap-props.js +14 -0
- package/lib/api/bootstrap/deploy-bootstrap.d.ts +39 -0
- package/lib/api/bootstrap/deploy-bootstrap.js +147 -0
- package/lib/api/bootstrap/index.d.ts +3 -0
- package/lib/api/bootstrap/index.js +23 -0
- package/lib/api/bootstrap/legacy-template.d.ts +2 -0
- package/lib/api/bootstrap/legacy-template.js +82 -0
- package/lib/api/cloud-assembly/environment.d.ts +43 -0
- package/lib/api/cloud-assembly/environment.js +127 -0
- package/lib/api/cloud-assembly/index.d.ts +1 -1
- package/lib/api/cloud-assembly/index.js +3 -3
- package/lib/api/cloud-assembly/private/context-aware-source.d.ts +1 -1
- package/lib/api/cloud-assembly/private/context-aware-source.js +5 -5
- package/lib/api/cloud-assembly/private/prepare-source.d.ts +2 -1
- package/lib/api/cloud-assembly/private/prepare-source.js +14 -12
- package/lib/api/cloud-assembly/private/readable-assembly.d.ts +1 -1
- package/lib/api/cloud-assembly/private/readable-assembly.js +1 -1
- package/lib/api/cloud-assembly/private/source-builder.js +10 -8
- package/lib/api/cloud-assembly/private/stack-assembly.d.ts +2 -1
- package/lib/api/cloud-assembly/private/stack-assembly.js +10 -9
- package/lib/api/cloud-assembly/stack-assembly.d.ts +55 -0
- package/lib/api/cloud-assembly/stack-assembly.js +139 -0
- package/lib/api/cloud-assembly/stack-collection.d.ts +27 -0
- package/lib/api/cloud-assembly/stack-collection.js +112 -0
- package/lib/api/cloud-assembly/stack-selector.d.ts +81 -2
- package/lib/api/cloud-assembly/stack-selector.js +62 -5
- package/lib/api/cloudformation/evaluate-cloudformation-template.d.ts +85 -0
- package/lib/api/cloudformation/evaluate-cloudformation-template.js +456 -0
- package/lib/api/cloudformation/index.d.ts +4 -0
- package/lib/api/cloudformation/index.js +21 -0
- package/lib/api/cloudformation/nested-stack-helpers.d.ts +25 -0
- package/lib/api/cloudformation/nested-stack-helpers.js +86 -0
- package/lib/api/cloudformation/stack-helpers.d.ts +96 -0
- package/lib/api/cloudformation/stack-helpers.js +163 -0
- package/lib/api/cloudformation/template-body-parameter.d.ts +22 -0
- package/lib/api/cloudformation/template-body-parameter.js +104 -0
- package/lib/api/context.d.ts +40 -0
- package/lib/api/context.js +84 -0
- package/lib/api/deployments/asset-manifest-builder.d.ts +8 -0
- package/lib/api/deployments/asset-manifest-builder.js +33 -0
- package/lib/api/deployments/asset-publishing.d.ts +60 -0
- package/lib/api/deployments/asset-publishing.js +144 -0
- package/lib/api/deployments/assets.d.ts +11 -0
- package/lib/api/deployments/assets.js +109 -0
- package/lib/api/deployments/cfn-api.d.ts +145 -0
- package/lib/api/deployments/cfn-api.js +444 -0
- package/lib/api/deployments/checks.d.ts +9 -0
- package/lib/api/deployments/checks.js +72 -0
- package/lib/api/deployments/deploy-stack.d.ts +164 -0
- package/lib/api/deployments/deploy-stack.js +490 -0
- package/lib/api/deployments/deployment-method.d.ts +24 -0
- package/lib/api/deployments/deployment-method.js +3 -0
- package/lib/api/deployments/deployment-result.d.ts +21 -0
- package/lib/api/deployments/deployment-result.js +10 -0
- package/lib/api/deployments/deployments.d.ts +289 -0
- package/lib/api/deployments/deployments.js +355 -0
- package/lib/api/deployments/index.d.ts +6 -0
- package/lib/api/deployments/index.js +27 -0
- package/lib/api/diff/diff-formatter.d.ts +147 -0
- package/lib/api/diff/diff-formatter.js +225 -0
- package/lib/api/diff/index.d.ts +1 -0
- package/lib/api/diff/index.js +18 -0
- package/lib/api/environment/environment-access.d.ts +139 -0
- package/lib/api/environment/environment-access.js +205 -0
- package/lib/api/environment/environment-resources.d.ts +75 -0
- package/lib/api/environment/environment-resources.js +213 -0
- package/lib/api/environment/index.d.ts +3 -0
- package/lib/api/environment/index.js +20 -0
- package/lib/api/environment/placeholders.d.ts +10 -0
- package/lib/api/environment/placeholders.js +23 -0
- package/lib/api/garbage-collection/garbage-collector.d.ts +158 -0
- package/lib/api/garbage-collection/garbage-collector.js +614 -0
- package/lib/api/garbage-collection/index.d.ts +3 -0
- package/lib/api/garbage-collection/index.js +21 -0
- package/lib/api/garbage-collection/progress-printer.d.ts +23 -0
- package/lib/api/garbage-collection/progress-printer.js +80 -0
- package/lib/api/garbage-collection/stack-refresh.d.ts +49 -0
- package/lib/api/garbage-collection/stack-refresh.js +152 -0
- package/lib/api/hotswap/appsync-mapping-templates.d.ts +4 -0
- package/lib/api/hotswap/appsync-mapping-templates.js +162 -0
- package/lib/api/hotswap/code-build-projects.d.ts +4 -0
- package/lib/api/hotswap/code-build-projects.js +62 -0
- package/lib/api/hotswap/common.d.ts +89 -0
- package/lib/api/hotswap/common.js +137 -0
- package/lib/api/hotswap/ecs-services.d.ts +4 -0
- package/lib/api/hotswap/ecs-services.js +159 -0
- package/lib/api/hotswap/hotswap-deployments.d.ts +17 -0
- package/lib/api/hotswap/hotswap-deployments.js +441 -0
- package/lib/api/hotswap/index.d.ts +2 -0
- package/lib/api/hotswap/index.js +19 -0
- package/lib/api/hotswap/lambda-functions.d.ts +4 -0
- package/lib/api/hotswap/lambda-functions.js +297 -0
- package/lib/api/hotswap/s3-bucket-deployments.d.ts +5 -0
- package/lib/api/hotswap/s3-bucket-deployments.js +117 -0
- package/lib/api/hotswap/stepfunctions-state-machines.d.ts +4 -0
- package/lib/api/hotswap/stepfunctions-state-machines.js +48 -0
- package/lib/api/index.d.ts +25 -0
- package/lib/api/index.js +42 -0
- package/lib/api/io/index.d.ts +3 -1
- package/lib/api/io/index.js +18 -1
- package/lib/api/io/io-host.d.ts +15 -0
- package/lib/api/io/io-host.js +3 -0
- package/lib/api/io/io-message.d.ts +76 -0
- package/lib/api/io/io-message.js +3 -0
- package/lib/api/io/private/index.d.ts +7 -1
- package/lib/api/io/private/index.js +8 -5
- package/lib/api/io/private/io-default-messages.d.ts +21 -0
- package/lib/api/io/private/io-default-messages.js +59 -0
- package/lib/api/io/private/io-helper.d.ts +32 -0
- package/lib/api/io/private/io-helper.js +51 -0
- package/lib/api/io/private/level-priority.d.ts +11 -0
- package/lib/api/io/private/level-priority.js +33 -0
- package/lib/api/io/private/message-maker.d.ts +89 -0
- package/lib/api/io/private/message-maker.js +60 -0
- package/lib/api/io/private/messages.d.ts +178 -0
- package/lib/api/io/private/messages.js +534 -0
- package/lib/api/io/private/span.d.ts +93 -0
- package/lib/api/io/private/span.js +87 -0
- package/lib/api/io/private/testing/fake-io-host.d.ts +28 -0
- package/lib/api/io/private/testing/fake-io-host.js +41 -0
- package/lib/api/io/private/testing/index.d.ts +2 -0
- package/lib/api/io/private/testing/index.js +19 -0
- package/lib/api/io/private/testing/test-io-host.d.ts +27 -0
- package/lib/api/io/private/testing/test-io-host.js +61 -0
- package/lib/api/io/private/types.d.ts +4 -0
- package/lib/api/io/private/types.js +3 -0
- package/lib/api/io/toolkit-action.d.ts +4 -0
- package/lib/api/io/toolkit-action.js +3 -0
- package/lib/api/logs-monitor/find-cloudwatch-logs.d.ts +25 -0
- package/lib/api/logs-monitor/find-cloudwatch-logs.js +95 -0
- package/lib/api/logs-monitor/index.d.ts +2 -0
- package/lib/api/logs-monitor/index.js +19 -0
- package/lib/api/logs-monitor/logs-monitor.d.ts +76 -0
- package/lib/api/logs-monitor/logs-monitor.js +194 -0
- package/lib/api/notices.d.ts +210 -0
- package/lib/api/notices.js +430 -0
- package/lib/api/plugin/context-provider-plugin.d.ts +6 -0
- package/lib/api/plugin/context-provider-plugin.js +7 -0
- package/lib/api/plugin/index.d.ts +3 -0
- package/lib/api/plugin/index.js +20 -0
- package/lib/api/plugin/mode.d.ts +4 -0
- package/lib/api/plugin/mode.js +9 -0
- package/lib/api/plugin/plugin.d.ts +72 -0
- package/lib/api/plugin/plugin.js +132 -0
- package/lib/api/private.d.ts +1 -0
- package/lib/api/private.js +18 -0
- package/lib/api/refactoring/cloudformation.d.ts +15 -0
- package/lib/api/refactoring/cloudformation.js +3 -0
- package/lib/api/refactoring/digest.d.ts +26 -0
- package/lib/api/refactoring/digest.js +175 -0
- package/lib/api/refactoring/index.d.ts +51 -0
- package/lib/api/refactoring/index.js +223 -0
- package/lib/api/require-approval.d.ts +17 -0
- package/lib/api/require-approval.js +22 -0
- package/lib/api/resource-import/importer.d.ts +216 -0
- package/lib/api/resource-import/importer.js +331 -0
- package/lib/api/resource-import/index.d.ts +2 -0
- package/lib/api/resource-import/index.js +19 -0
- package/lib/api/resource-import/migrator.d.ts +26 -0
- package/lib/api/resource-import/migrator.js +73 -0
- package/lib/api/resource-metadata/index.d.ts +1 -0
- package/lib/api/resource-metadata/index.js +18 -0
- package/lib/api/resource-metadata/resource-metadata.d.ts +24 -0
- package/lib/api/resource-metadata/resource-metadata.js +42 -0
- package/lib/api/rwlock.d.ts +60 -0
- package/lib/api/rwlock.js +204 -0
- package/lib/api/settings.d.ts +26 -0
- package/lib/api/settings.js +107 -0
- package/lib/api/shared-private.d.ts +8 -5
- package/lib/api/shared-private.js +2921 -9246
- package/lib/api/shared-private.js.map +4 -4
- package/lib/api/shared-public.d.ts +179 -37
- package/lib/api/shared-public.js +3106 -16
- package/lib/api/shared-public.js.map +4 -4
- package/lib/api/stack-events/index.d.ts +4 -0
- package/lib/api/stack-events/index.js +23 -0
- package/lib/api/stack-events/stack-activity-monitor.d.ts +100 -0
- package/lib/api/stack-events/stack-activity-monitor.js +164 -0
- package/lib/api/stack-events/stack-event-poller.d.ts +69 -0
- package/lib/api/stack-events/stack-event-poller.js +130 -0
- package/lib/api/stack-events/stack-progress-monitor.d.ts +48 -0
- package/lib/api/stack-events/stack-progress-monitor.js +98 -0
- package/lib/api/stack-events/stack-status.d.ts +42 -0
- package/lib/api/stack-events/stack-status.js +90 -0
- package/lib/api/streams.d.ts +7 -0
- package/lib/api/streams.js +24 -0
- package/lib/api/tags.d.ts +9 -0
- package/lib/api/tags.js +10 -0
- package/lib/api/toolkit-error.d.ts +86 -0
- package/lib/api/toolkit-error.js +132 -0
- package/lib/api/toolkit-info.d.ts +52 -0
- package/lib/api/toolkit-info.js +157 -0
- package/lib/api/tree.d.ts +31 -0
- package/lib/api/tree.js +37 -0
- package/lib/api/work-graph/index.d.ts +3 -0
- package/lib/api/work-graph/index.js +20 -0
- package/lib/api/work-graph/work-graph-builder.d.ts +34 -0
- package/lib/api/work-graph/work-graph-builder.js +172 -0
- package/lib/api/work-graph/work-graph-types.d.ts +50 -0
- package/lib/api/work-graph/work-graph-types.js +13 -0
- package/lib/api/work-graph/work-graph.d.ts +72 -0
- package/lib/api/work-graph/work-graph.js +349 -0
- package/lib/context-providers/ami.d.ts +13 -0
- package/lib/context-providers/ami.js +52 -0
- package/lib/context-providers/availability-zones.d.ts +13 -0
- package/lib/context-providers/availability-zones.js +29 -0
- package/lib/context-providers/cc-api-provider.d.ts +30 -0
- package/lib/context-providers/cc-api-provider.js +145 -0
- package/lib/context-providers/endpoint-service-availability-zones.d.ts +13 -0
- package/lib/context-providers/endpoint-service-availability-zones.js +35 -0
- package/lib/context-providers/hosted-zones.d.ts +12 -0
- package/lib/context-providers/hosted-zones.js +69 -0
- package/lib/context-providers/index.d.ts +44 -0
- package/lib/context-providers/index.js +128 -0
- package/lib/context-providers/keys.d.ts +13 -0
- package/lib/context-providers/keys.js +54 -0
- package/lib/context-providers/load-balancers.d.ts +20 -0
- package/lib/context-providers/load-balancers.js +161 -0
- package/lib/context-providers/security-groups.d.ts +9 -0
- package/lib/context-providers/security-groups.js +69 -0
- package/lib/context-providers/ssm-parameters.d.ts +25 -0
- package/lib/context-providers/ssm-parameters.js +61 -0
- package/lib/context-providers/vpcs.d.ts +13 -0
- package/lib/context-providers/vpcs.js +291 -0
- package/lib/index.d.ts +1 -0
- package/lib/index.js +2 -1
- package/lib/index_bg.wasm +0 -0
- package/lib/payloads/bootstrap-environment-progress.d.ts +17 -0
- package/lib/payloads/bootstrap-environment-progress.js +3 -0
- package/lib/payloads/context.d.ts +9 -0
- package/lib/payloads/context.js +3 -0
- package/lib/payloads/deploy.d.ts +43 -0
- package/lib/payloads/deploy.js +3 -0
- package/lib/payloads/destroy.d.ts +23 -0
- package/lib/payloads/destroy.js +3 -0
- package/lib/payloads/diff.d.ts +31 -0
- package/lib/payloads/diff.js +22 -0
- package/lib/payloads/hotswap.d.ts +211 -0
- package/lib/payloads/hotswap.js +43 -0
- package/lib/payloads/index.d.ts +17 -0
- package/lib/payloads/index.js +34 -0
- package/lib/payloads/list.d.ts +4 -0
- package/lib/payloads/list.js +3 -0
- package/lib/payloads/logs-monitor.d.ts +33 -0
- package/lib/payloads/logs-monitor.js +3 -0
- package/lib/payloads/progress.d.ts +14 -0
- package/lib/payloads/progress.js +3 -0
- package/lib/payloads/refactor.d.ts +14 -0
- package/lib/payloads/refactor.js +3 -0
- package/lib/payloads/rollback.d.ts +17 -0
- package/lib/payloads/rollback.js +3 -0
- package/lib/payloads/sdk-trace.d.ts +20 -0
- package/lib/payloads/sdk-trace.js +3 -0
- package/lib/payloads/stack-activity.d.ts +53 -0
- package/lib/payloads/stack-activity.js +3 -0
- package/lib/payloads/stack-details.d.ts +17 -0
- package/lib/payloads/stack-details.js +3 -0
- package/lib/payloads/synth.d.ts +7 -0
- package/lib/payloads/synth.js +3 -0
- package/lib/payloads/types.d.ts +95 -0
- package/lib/payloads/types.js +3 -0
- package/lib/payloads/watch.d.ts +27 -0
- package/lib/payloads/watch.js +3 -0
- package/lib/private/activity-printer/base.d.ts +50 -0
- package/lib/private/activity-printer/base.js +120 -0
- package/lib/private/activity-printer/current.d.ts +26 -0
- package/lib/private/activity-printer/current.js +122 -0
- package/lib/private/activity-printer/display.d.ts +13 -0
- package/lib/private/activity-printer/display.js +81 -0
- package/lib/private/activity-printer/history.d.ts +32 -0
- package/lib/private/activity-printer/history.js +109 -0
- package/lib/private/activity-printer/index.d.ts +3 -0
- package/lib/private/activity-printer/index.js +20 -0
- package/lib/private/index.d.ts +1 -0
- package/lib/private/index.js +18 -0
- package/lib/private/util.d.ts +1 -1
- package/lib/private/util.js +22 -22
- package/lib/private/util.js.map +2 -2
- package/lib/toolkit/private/index.d.ts +2 -0
- package/lib/toolkit/private/index.js +1 -1
- package/lib/toolkit/toolkit.d.ts +16 -0
- package/lib/toolkit/toolkit.js +158 -124
- package/lib/toolkit/types.d.ts +0 -55
- package/lib/toolkit/types.js +1 -1
- package/lib/util/archive.d.ts +1 -0
- package/lib/util/archive.js +86 -0
- package/lib/util/arrays.d.ts +14 -0
- package/lib/util/arrays.js +36 -0
- package/lib/util/bool.d.ts +7 -0
- package/lib/util/bool.js +13 -0
- package/lib/util/bytes.d.ts +8 -0
- package/lib/util/bytes.js +21 -0
- package/lib/util/cloudformation.d.ts +16 -0
- package/lib/util/cloudformation.js +36 -0
- package/lib/util/content-hash.d.ts +5 -0
- package/lib/util/content-hash.js +43 -0
- package/lib/util/directories.d.ts +22 -0
- package/lib/util/directories.js +59 -0
- package/lib/util/format-error.d.ts +9 -0
- package/lib/util/format-error.js +22 -0
- package/lib/util/index.d.ts +18 -0
- package/lib/util/index.js +35 -0
- package/lib/util/json.d.ts +48 -0
- package/lib/util/json.js +68 -0
- package/lib/util/objects.d.ts +65 -0
- package/lib/util/objects.js +230 -0
- package/lib/util/package-info.d.ts +3 -0
- package/lib/util/package-info.js +22 -0
- package/lib/util/parallel.d.ts +6 -0
- package/lib/util/parallel.js +48 -0
- package/lib/util/serialize.d.ts +27 -0
- package/lib/util/serialize.js +86 -0
- package/lib/util/string-manipulation.d.ts +18 -0
- package/lib/util/string-manipulation.js +46 -0
- package/lib/util/type-brands.d.ts +39 -0
- package/lib/util/type-brands.js +39 -0
- package/lib/util/types.d.ts +27 -0
- package/lib/util/types.js +25 -0
- package/lib/util/version-range.d.ts +2 -0
- package/lib/util/version-range.js +36 -0
- package/lib/util/yaml-cfn.d.ts +15 -0
- package/lib/util/yaml-cfn.js +58 -0
- package/package.json +12 -13
|
@@ -1021,7 +1021,10 @@ export declare class AssemblyError extends ToolkitError {
|
|
|
1021
1021
|
readonly stacks?: cxapi.CloudFormationStackArtifact[];
|
|
1022
1022
|
private constructor();
|
|
1023
1023
|
}
|
|
1024
|
-
|
|
1024
|
+
/**
|
|
1025
|
+
* Represents an error originating from a Context Provider
|
|
1026
|
+
*/
|
|
1027
|
+
export declare class ContextProviderError extends ToolkitError {
|
|
1025
1028
|
/**
|
|
1026
1029
|
* Denotes the source of the error as user.
|
|
1027
1030
|
*/
|
|
@@ -1109,6 +1112,19 @@ export interface StackSelector {
|
|
|
1109
1112
|
*/
|
|
1110
1113
|
failOnEmpty?: boolean;
|
|
1111
1114
|
}
|
|
1115
|
+
/**
|
|
1116
|
+
* Metadata entry for a resource within a CloudFormation stack
|
|
1117
|
+
*/
|
|
1118
|
+
export interface ResourceMetadata {
|
|
1119
|
+
/**
|
|
1120
|
+
* The resource's metadata as declared in the cloud assembly
|
|
1121
|
+
*/
|
|
1122
|
+
readonly entry: MetadataEntry;
|
|
1123
|
+
/**
|
|
1124
|
+
* The construct path of the resource
|
|
1125
|
+
*/
|
|
1126
|
+
readonly constructPath: string;
|
|
1127
|
+
}
|
|
1112
1128
|
/**
|
|
1113
1129
|
* The current action being performed by the CLI. 'none' represents the absence of an action.
|
|
1114
1130
|
*/
|
|
@@ -1202,6 +1218,168 @@ export interface IIoHost {
|
|
|
1202
1218
|
*/
|
|
1203
1219
|
requestResponse<T, U>(msg: IoRequest<T, U>): Promise<U>;
|
|
1204
1220
|
}
|
|
1221
|
+
type ForReading = 0;
|
|
1222
|
+
type ForWriting = 1;
|
|
1223
|
+
interface CredentialProviderSource {
|
|
1224
|
+
name: string;
|
|
1225
|
+
/**
|
|
1226
|
+
* Whether the credential provider is even online
|
|
1227
|
+
*
|
|
1228
|
+
* Guaranteed to be called before any of the other functions are called.
|
|
1229
|
+
*/
|
|
1230
|
+
isAvailable(): Promise<boolean>;
|
|
1231
|
+
/**
|
|
1232
|
+
* Whether the credential provider can provide credentials for the given account.
|
|
1233
|
+
*/
|
|
1234
|
+
canProvideCredentials(accountId: string): Promise<boolean>;
|
|
1235
|
+
/**
|
|
1236
|
+
* Construct a credential provider for the given account and the given access mode
|
|
1237
|
+
*
|
|
1238
|
+
* Guaranteed to be called only if canProvideCredentials() returned true at some point.
|
|
1239
|
+
*
|
|
1240
|
+
* While it is possible for the plugin to return a static set of credentials, it is
|
|
1241
|
+
* recommended to return a provider.
|
|
1242
|
+
*/
|
|
1243
|
+
getProvider(accountId: string, mode: ForReading | ForWriting, options?: PluginProviderOptions): Promise<PluginProviderResult>;
|
|
1244
|
+
}
|
|
1245
|
+
interface IPluginHost {
|
|
1246
|
+
/**
|
|
1247
|
+
* Registers a credential provider source. If, in the authentication process,
|
|
1248
|
+
* the CLI decides to try credentials from the plugins, it will go through the
|
|
1249
|
+
* sources registered in this way, in the same order as they were registered.
|
|
1250
|
+
*/
|
|
1251
|
+
registerCredentialProviderSource(source: CredentialProviderSource): void;
|
|
1252
|
+
}
|
|
1253
|
+
interface PluginProviderOptions {
|
|
1254
|
+
/**
|
|
1255
|
+
* Whether or not this implementation of the CLI will recognize the `SDKv3CompatibleCredentialProvider` return variant
|
|
1256
|
+
*
|
|
1257
|
+
* Unless otherwise indicated, the CLI version will only support SDKv3
|
|
1258
|
+
* credentials, not SDKv3 providers. You should avoid returning types that the
|
|
1259
|
+
* consuming CLI will not understand, because it will most likely crash.
|
|
1260
|
+
*
|
|
1261
|
+
* @default false
|
|
1262
|
+
*/
|
|
1263
|
+
readonly supportsV3Providers?: boolean;
|
|
1264
|
+
}
|
|
1265
|
+
type PluginProviderResult = SDKv2CompatibleCredentials | SDKv3CompatibleCredentialProvider | SDKv3CompatibleCredentials;
|
|
1266
|
+
interface SDKv2CompatibleCredentials {
|
|
1267
|
+
/**
|
|
1268
|
+
* AWS access key ID.
|
|
1269
|
+
*/
|
|
1270
|
+
accessKeyId: string;
|
|
1271
|
+
/**
|
|
1272
|
+
* Time when credentials should be considered expired.
|
|
1273
|
+
* Used in conjunction with expired.
|
|
1274
|
+
*/
|
|
1275
|
+
expireTime?: Date | null;
|
|
1276
|
+
/**
|
|
1277
|
+
* AWS secret access key.
|
|
1278
|
+
*/
|
|
1279
|
+
secretAccessKey: string;
|
|
1280
|
+
/**
|
|
1281
|
+
* AWS session token.
|
|
1282
|
+
*/
|
|
1283
|
+
sessionToken?: string;
|
|
1284
|
+
/**
|
|
1285
|
+
* Gets the existing credentials, refreshing them if necessary, and returns
|
|
1286
|
+
* a promise that will be fulfilled immediately (if no refresh is necessary)
|
|
1287
|
+
* or when the refresh has completed.
|
|
1288
|
+
*/
|
|
1289
|
+
getPromise(): Promise<void>;
|
|
1290
|
+
}
|
|
1291
|
+
type SDKv3CompatibleCredentialProvider = (identityProperties?: Record<string, any>) => Promise<SDKv3CompatibleCredentials>;
|
|
1292
|
+
interface SDKv3CompatibleCredentials {
|
|
1293
|
+
/**
|
|
1294
|
+
* AWS access key ID
|
|
1295
|
+
*/
|
|
1296
|
+
readonly accessKeyId: string;
|
|
1297
|
+
/**
|
|
1298
|
+
* AWS secret access key
|
|
1299
|
+
*/
|
|
1300
|
+
readonly secretAccessKey: string;
|
|
1301
|
+
/**
|
|
1302
|
+
* A security or session token to use with these credentials. Usually
|
|
1303
|
+
* present for temporary credentials.
|
|
1304
|
+
*/
|
|
1305
|
+
readonly sessionToken?: string;
|
|
1306
|
+
/**
|
|
1307
|
+
* A `Date` when the identity or credential will no longer be accepted.
|
|
1308
|
+
*/
|
|
1309
|
+
readonly expiration?: Date;
|
|
1310
|
+
}
|
|
1311
|
+
export interface ContextProviderPlugin {
|
|
1312
|
+
getValue(args: {
|
|
1313
|
+
[key: string]: any;
|
|
1314
|
+
}): Promise<any>;
|
|
1315
|
+
}
|
|
1316
|
+
/**
|
|
1317
|
+
* Class to manage a plugin collection
|
|
1318
|
+
*
|
|
1319
|
+
* It provides a `load()` function that loads a JavaScript
|
|
1320
|
+
* module from disk, and gives it access to the `IPluginHost` interface
|
|
1321
|
+
* to register itself.
|
|
1322
|
+
*/
|
|
1323
|
+
export declare class PluginHost implements IPluginHost {
|
|
1324
|
+
/**
|
|
1325
|
+
* Access the currently registered CredentialProviderSources. New sources can
|
|
1326
|
+
* be registered using the +registerCredentialProviderSource+ method.
|
|
1327
|
+
*/
|
|
1328
|
+
readonly credentialProviderSources: CredentialProviderSource[];
|
|
1329
|
+
readonly contextProviderPlugins: Record<string, ContextProviderPlugin>;
|
|
1330
|
+
ioHost?: IIoHost;
|
|
1331
|
+
private readonly alreadyLoaded;
|
|
1332
|
+
/**
|
|
1333
|
+
* Loads a plug-in into this PluginHost.
|
|
1334
|
+
*
|
|
1335
|
+
* Will use `require.resolve()` to get the most accurate representation of what
|
|
1336
|
+
* code will get loaded in error messages. As such, it will not work in
|
|
1337
|
+
* unit tests with Jest virtual modules becauase of <https://github.com/jestjs/jest/issues/9543>.
|
|
1338
|
+
*
|
|
1339
|
+
* @param moduleSpec the specification (path or name) of the plug-in module to be loaded.
|
|
1340
|
+
* @param ioHost the I/O host to use for printing progress information
|
|
1341
|
+
*/
|
|
1342
|
+
load(moduleSpec: string, ioHost?: IIoHost): void;
|
|
1343
|
+
/**
|
|
1344
|
+
* Allows plug-ins to register new CredentialProviderSources.
|
|
1345
|
+
*
|
|
1346
|
+
* @param source a new CredentialProviderSource to register.
|
|
1347
|
+
*/
|
|
1348
|
+
registerCredentialProviderSource(source: CredentialProviderSource): void;
|
|
1349
|
+
/**
|
|
1350
|
+
* (EXPERIMENTAL) Allow plugins to register context providers
|
|
1351
|
+
*
|
|
1352
|
+
* Context providers are objects with the following method:
|
|
1353
|
+
*
|
|
1354
|
+
* ```ts
|
|
1355
|
+
* getValue(args: {[key: string]: any}): Promise<any>;
|
|
1356
|
+
* ```
|
|
1357
|
+
*
|
|
1358
|
+
* Currently, they cannot reuse the CDK's authentication mechanisms, so they
|
|
1359
|
+
* must be prepared to either not make AWS calls or use their own source of
|
|
1360
|
+
* AWS credentials.
|
|
1361
|
+
*
|
|
1362
|
+
* This feature is experimental, and only intended to be used internally at Amazon
|
|
1363
|
+
* as a trial.
|
|
1364
|
+
*
|
|
1365
|
+
* After registering with 'my-plugin-name', the provider must be addressed as follows:
|
|
1366
|
+
*
|
|
1367
|
+
* ```ts
|
|
1368
|
+
* const value = ContextProvider.getValue(this, {
|
|
1369
|
+
* providerName: 'plugin',
|
|
1370
|
+
* props: {
|
|
1371
|
+
* pluginName: 'my-plugin-name',
|
|
1372
|
+
* myParameter1: 'xyz',
|
|
1373
|
+
* },
|
|
1374
|
+
* includeEnvironment: true | false,
|
|
1375
|
+
* dummyValue: 'what-to-return-on-the-first-pass',
|
|
1376
|
+
* })
|
|
1377
|
+
* ```
|
|
1378
|
+
*
|
|
1379
|
+
* @experimental
|
|
1380
|
+
*/
|
|
1381
|
+
registerContextProviderAlpha(pluginProviderName: string, provider: ContextProviderPlugin): void;
|
|
1382
|
+
}
|
|
1205
1383
|
export interface BootstrapEnvironmentProgress {
|
|
1206
1384
|
/**
|
|
1207
1385
|
* The total number of environments being deployed
|
|
@@ -1438,32 +1616,6 @@ export interface DeployConfirmationRequest extends ConfirmationRequest {
|
|
|
1438
1616
|
*/
|
|
1439
1617
|
readonly permissionChangeType: PermissionChangeType;
|
|
1440
1618
|
}
|
|
1441
|
-
export interface StackDeployProgress {
|
|
1442
|
-
/**
|
|
1443
|
-
* The total number of stacks being deployed
|
|
1444
|
-
*/
|
|
1445
|
-
readonly total: number;
|
|
1446
|
-
/**
|
|
1447
|
-
* The count of the stack currently attempted to be deployed
|
|
1448
|
-
*
|
|
1449
|
-
* This is counting value, not an identifier.
|
|
1450
|
-
*/
|
|
1451
|
-
readonly current: number;
|
|
1452
|
-
/**
|
|
1453
|
-
* The stack that's currently being deployed
|
|
1454
|
-
*/
|
|
1455
|
-
readonly stack: CloudFormationStackArtifact;
|
|
1456
|
-
}
|
|
1457
|
-
/**
|
|
1458
|
-
* Payload for a yes/no confirmation in deploy. Includes information on
|
|
1459
|
-
* what kind of change is being made.
|
|
1460
|
-
*/
|
|
1461
|
-
export interface DeployConfirmationRequest extends ConfirmationRequest {
|
|
1462
|
-
/**
|
|
1463
|
-
* The type of change being made to the IAM permissions.
|
|
1464
|
-
*/
|
|
1465
|
-
readonly permissionChangeType: PermissionChangeType;
|
|
1466
|
-
}
|
|
1467
1619
|
export interface BuildAsset {
|
|
1468
1620
|
/**
|
|
1469
1621
|
* The asset that is build
|
|
@@ -1576,16 +1728,6 @@ export interface StackProgress {
|
|
|
1576
1728
|
*/
|
|
1577
1729
|
readonly formatted: string;
|
|
1578
1730
|
}
|
|
1579
|
-
interface ResourceMetadata {
|
|
1580
|
-
/**
|
|
1581
|
-
* The resource's metadata as declared in the cloud assembly
|
|
1582
|
-
*/
|
|
1583
|
-
readonly entry: MetadataEntry;
|
|
1584
|
-
/**
|
|
1585
|
-
* The construct path of the resource
|
|
1586
|
-
*/
|
|
1587
|
-
readonly constructPath: string;
|
|
1588
|
-
}
|
|
1589
1731
|
/**
|
|
1590
1732
|
* Payload when stack monitoring is starting or stopping for a given stack deployment.
|
|
1591
1733
|
*/
|