diff --git a/lerna.json b/lerna.json index 0867af78081e7..fca71760dbe9a 100644 --- a/lerna.json +++ b/lerna.json @@ -6,6 +6,7 @@ "packages/*", "packages/@aws-cdk/*", "packages/@aws-cdk-containers/*", + "packages/@aws-cdk-testing/*", "packages/@aws-cdk/*/lambda-packages/*", "tools/*", "tools/@aws-cdk/*", diff --git a/package.json b/package.json index 7e4c19662c7b4..5fd979f948810 100644 --- a/package.json +++ b/package.json @@ -68,6 +68,7 @@ "packages/*", "packages/@aws-cdk/*", "packages/@aws-cdk-containers/*", + "packages/@aws-cdk-testing/*", "packages/@aws-cdk/*/lambda-packages/*", "tools/*", "tools/@aws-cdk/*", diff --git a/packages/@aws-cdk-testing/cli-integ/.eslintrc.js b/packages/@aws-cdk-testing/cli-integ/.eslintrc.js new file mode 100644 index 0000000000000..77f8007f9fc90 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/.eslintrc.js @@ -0,0 +1,4 @@ +const baseConfig = require('@aws-cdk/cdk-build-tools/config/eslintrc'); +baseConfig.ignorePatterns.push('resources/**/*'); +baseConfig.parserOptions.project = __dirname + '/tsconfig.json'; +module.exports = baseConfig; diff --git a/packages/@aws-cdk-testing/cli-integ/.gitignore b/packages/@aws-cdk-testing/cli-integ/.gitignore new file mode 100644 index 0000000000000..eb8b474f4ca2a --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/.gitignore @@ -0,0 +1,20 @@ +*.js +*.js.map +*.d.ts +!resources/**/* +node_modules +dist + +.LAST_BUILD +.nyc_output +coverage +nyc.config.js +.LAST_PACKAGE +*.snk + +!.eslintrc.js +!jest.config.js + +.DS_Store + +junit.xml diff --git a/packages/@aws-cdk-testing/cli-integ/.npmignore b/packages/@aws-cdk-testing/cli-integ/.npmignore new file mode 100644 index 0000000000000..b2a3ba40d9011 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/.npmignore @@ -0,0 +1,32 @@ +# Don't include original .ts files when doing `npm pack` +*.ts +!*.d.ts +coverage +.nyc_output +*.tgz + +dist +.LAST_PACKAGE +.LAST_BUILD +*.snk + +!test/integ/run-wrappers/dist + +*.tsbuildinfo + +jest.config.js +tsconfig.json +.eslintrc.js + +!test/integ/cli/jest.config.js +!test/integ/uberpackage/jest.config.js +!resources/ +!resources/**/* + +.DS_Store + +junit.xml + +# exclude cdk artifacts +**/cdk.out +test/ diff --git a/packages/@aws-cdk-testing/cli-integ/LICENSE b/packages/@aws-cdk-testing/cli-integ/LICENSE new file mode 100644 index 0000000000000..9b722c65c5481 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright 2018-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/packages/@aws-cdk-testing/cli-integ/NOTICE b/packages/@aws-cdk-testing/cli-integ/NOTICE new file mode 100644 index 0000000000000..0dd703eaedb4a --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/NOTICE @@ -0,0 +1,16 @@ +AWS Cloud Development Kit (AWS CDK) +Copyright 2018-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. + +Third party attributions of this package can be found in the THIRD_PARTY_LICENSES file diff --git a/packages/@aws-cdk-testing/cli-integ/README.md b/packages/@aws-cdk-testing/cli-integ/README.md new file mode 100644 index 0000000000000..deafd6a5a8841 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/README.md @@ -0,0 +1,151 @@ +# CDK CLI integration test + + +--- + +![cdk-constructs: Experimental](https://img.shields.io/badge/cdk--constructs-experimental-important.svg?style=for-the-badge) + +> The APIs of higher level constructs in this module are experimental and under active development. +> They are subject to non-backward compatible changes or removal in any future version. These are +> not subject to the [Semantic Versioning](https://semver.org/) model and breaking changes will be +> announced in the release notes. This means that while you may use them, you may need to update +> your source code when upgrading to a newer version of this package. + +--- + + + +This package contains CDK CLI integration test suites, as well as helper tools necessary to run those suites against various different distributions of the CDK (in the source repository, against a build directory, or against published releases). + +> The tools and tests themselves should arguably be in different packages, but I want to prevent package proliferation. For now we'll keep them together. + +## Tests + +The tests themselves are in the `tests/` directory: + +```text +tests/ +├── cli-integ-tests +├── init-csharp +├── init-fsharp +├── init-java +├── init-javascript +├── init-python +├── init-typescript-app +├── init-typescript-lib +└── uberpackage +``` + +Each subdirectory contains one test **suite**, and in the development pipeline each suite is run individually in a CodeBuild job, all in parallel. This requires manual configuration in the pipeline: to add a new suite, first add a suite here, then add the suite to the pipeline as well. The safest strategy is to add a trivially succeeding suite first (for example, a single test with `expect(true).toBeTruthy()`), add it to the pipeline, and then write the actual tests. + +Test suites are written as a collection of Jest tests, and they are run using Jest, using the code in the `lib/` directory as helpers. + +### Running a test suite + +You run a suite using the `bin/run-suite` tool. You must select either a version of the CLI and framework which can be `npm install`ed, or point to the root of the source tree: + +```shell +# Use the given source tree +$ bin/run-suite --use-source=/path/to/repo-root + +# Automatically determine the source tree root +$ bin/run-suite -a + +# Run against a released version +$ bin/run-suite --use-cli-release=2.34.5 +``` + +To run a specific test, add `-t` and a substring of the test name. For example: + +```shell +bin/run-suite -a cli-integ-tests -t 'load old assemblies' +``` + +## Tools + +There are a number of tools in the `bin/` directory. They are: + +```text +bin/ +├── apply-patches +├── query-github +├── run-suite +├── stage-distribution +└── test-root +``` + +* `apply-patches`: used for regression testing. Applies patches to historical versions of the tests to fix false positive test failures. +* `query-github`: used for regression testing. Queries GitHub for previously released versions. +* `run-suite`: run one of the test suites in the `tests/` directory. +* `stage-distribution`: used for testing in the pipeline. Uploads candidate release binaries to CodeArtifact so that they can be installed using `npm install`, `pip install`, etc. +* `test-root`: return the directory containing all tests (used for applying patches). + +## Regression testing + +The regression testing mechanism is somewhat involved and therefore deserves its own section. The principle is not too hard to explain though: + +*We run the previous version of the CLI integ tests against the new candidate release of the CLI, to make sure we didn't accidentally introduce any breaking behavior*. + +This is slightly complicated by two facts: + +* (1) Both the CLI and the framework may have changed, and an incompatibility may have arisen between the framework and CLI. Newer CLIs must always support older framework versions. We therefore run two flavors of the integration tests: + * Old tests, new CLI, new framework + * Old tests, new CLI, old framework + +The testing matrix looks like this: + +```text + OLD TESTS NEW TESTS + + CLI CLI + Old New Old New + ┌────────┬────────┐ ┌────────┬────────┐ + F'WORK │ prev │ │ F'WORK │ │ │ + Old │ rls │ regr │ Old │ (N/A) │ ? │ + │ integ │ │ │ │ │ + ├────────┼────────┤ ├────────┼────────┤ + │ │ │ │ │ cur │ + New │ (N/A) │ regr │ New │ (N/A) │ rls │ + │ │ │ │ │ integ │ + └────────┴────────┘ └────────┴────────┘ +``` + +We are covering everything except "new tests, new CLI, old framework", which is not clear that it even makes sense to test because some new features may rely on framework support which will not be in the old version yet. + +* (2) Sometimes, old tests will fail on newer releases when we introduce breaking changes to the framework or CLI for something serious (such as security reasons), or maybe because we had a bug in an old version that happened to pass, but now the test needs to be updated in order to pass a bugfix. + +For this case we have a patching mechanism, so that in a NEW release of the tools, we include files that are copied over an OLD release of the test, that allows them to pass. For the simplest case there is a mechanism to suppress the run of a single test, so that we can skip the running of one test for one release. For more complicated cases we copy in patched `.js` source files which will replace old source files. (Patches are considered part of the *tools*, not part of the *tests*). + +### Mechanism + +To run the tests in a regressory fashion, do the following: + +* Download the current `@aws-cdk-testing/cli-integ` artifact at `V1`. +* Determine the previous version `V0` (use `query-github` for this). +* Download the previous `@aws-cdk-testing/cli-integ` artifact at `V0`. +* From the `V1` artifact, apply the `V0` patch set. +* Run the `V0` tests with the `--framework-version` option: + +```shell +# Old tests, new CLI, new framework +V0/bin/run-suite --use-cli-release=V1 --framework-version=V1 [...] + +# Old tests, new CLI, old framework +V0/bin/run-suite --use-cli-release=V1 --framework-version=V0 [...] +``` + +### Patching + +To patch a previous set of tests to make them pass with a new release, add a directory to `resources/cli-regression-patches`. The simplest method is to add a `skip-tests.txt` file: + +```shell +# The version of the tests that are currently failing (V0 in the paragraph above) +export VERSION=X.Y.Z + +mkdir -p resources/cli-regression-patches/v${VERSION} +cp skip-tests.txt resources/cli-regression-patches/v${VERSION}/ +``` + +Now edit `resources/cli-regression-patches/vX.Y.Z/skip-tests.txt` and put the name of the test you want to skip on a line by itself. + +If you need to replace source files, it's probably best to stick compiled `.js` files in here. `.ts` source files wouldn't compile because they'd be missing `imports`. diff --git a/packages/@aws-cdk-testing/cli-integ/bin/apply-patches b/packages/@aws-cdk-testing/cli-integ/bin/apply-patches new file mode 100755 index 0000000000000..b27d0c93dc9e7 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/bin/apply-patches @@ -0,0 +1,19 @@ +#!/bin/bash +# Written in bash just because that's easier with all the file manipulation +set -eu +scriptdir=$(cd $(dirname $0) && pwd) +version="$1" +target_dir="$2" + + +if [[ ! -f "$2/skip-tests.txt" ]]; then + echo "$2: does not look like a test root directory." >&2 + exit 1 +fi + + +candidate_dir="${scriptdir}/../resources/cli-regression-patches/v${version}" + +if [[ -f "$candidate_dir" ]]; then + cp -R "${candidate_dir}/"* "$2" +fi \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/bin/download-and-run-old-tests b/packages/@aws-cdk-testing/cli-integ/bin/download-and-run-old-tests new file mode 100755 index 0000000000000..ad72ce50c0991 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/bin/download-and-run-old-tests @@ -0,0 +1,52 @@ +#!/bin/bash +set -eu +# Download old tests and run them. Written in bash, just because. Needs to do contortions, see below. +# +# Usage: +# +# download-and-run-old-tests [...args to run-suite...] +set -x + +scriptdir=$(cd $(dirname $0) && pwd) + +version="$1" +target_directory="old_tests" +shift + +rm -rf $target_directory && mkdir $target_directory + +# The old tests package MUST be 'npm install 'ed as a dependency, but MUST NOT +# end up in a `node_modules` directory. +# +# - MUST be 'npm install'ed: we need transitive dependencies as well. +# - as a dependency: if we check out the source and do an `npm install --production` in the +# package.json directory, NPM will still try to resolve devDependencies (even though it doesn't +# need to install them), and the devDeps do not exist on npmjs. +# - MUST NOT end up in `node_modules`: Jest 27 will ignore all tests that have `node_modules` in +# the path, and this behavior is not configurable before Jest 28. Unfortunately, because of TypeScript +# typing issues, we cannot move past Jest 27. +# +# To achieve this, do an `npm install ` then follow up with an `mv` to move the files out. +if ! npm install --prefix $target_directory --no-save @aws-cdk-testing/cli-integ@$version > npm.log 2>&1; then + cat npm.log >&2 + # Catch a "package does not exist" error, have to do it this way because for some reason, + # 'npm view ' doesn't exit with an error... :s + if grep -q 'code ETARGET' npm.log; then + echo "During migration, @aws-cdk-testing/cli-integ@$version does not exist yet." >&2 + + + # Do create an empty junit.xml file -- if we don't, then the "upload report" phase will fail + # if there are 0 files to upload. + echo '' > junit.xml + exit 0 + fi + exit 1 +fi + +mv $($target_directory/node_modules/.bin/test-root)/* $target_directory + +# Apply new patches to old tests +${scriptdir}/apply-patches $version $target_directory + +# Run the suite from the old tests +exec $target_directory/bin/run-suite "$@" \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/bin/query-github b/packages/@aws-cdk-testing/cli-integ/bin/query-github new file mode 100755 index 0000000000000..fbb9b1fa5f199 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/bin/query-github @@ -0,0 +1,2 @@ +#!/usr/bin/env node +require('./query-github.js'); diff --git a/packages/@aws-cdk-testing/cli-integ/bin/query-github.ts b/packages/@aws-cdk-testing/cli-integ/bin/query-github.ts new file mode 100644 index 0000000000000..33da60c57f618 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/bin/query-github.ts @@ -0,0 +1,58 @@ +// eslint-disable-next-line jest/no-jest-import +import * as yargs from 'yargs'; +import { fetchPreviousVersion } from '../lib/github'; + +async function main() { + const args = await yargs + .option('token', { + descripton: 'GitHub token (default: from environment GITHUB_TOKEN)', + alias: 't', + type: 'string', + requiresArg: true, + }) + .command('last-release', 'Query the last release', cmd => cmd + .option('prior-to', { + description: 'Return the most recent release before the given version', + alias: 'p', + type: 'string', + requiresArg: true, + }) + .option('major', { + description: 'Return the most recent release that matches', + alias: 'm', + type: 'string', + requiresArg: true, + })) + .demandCommand() + .help() + .strictOptions() + .showHelpOnFail(false) + .argv; + + const command = args._[0]; + + const token = args.token ?? process.env.GITHUB_TOKEN; + if (!token) { + throw new Error('Either pass --token or set GITHUB_TOKEN.'); + } + + switch (command) { + case 'last-release': + if (args['prior-to'] && args.major) { + throw new Error('Cannot pass both `--prior-to and --major at the same time'); + } + + // eslint-disable-next-line no-console + console.log(await fetchPreviousVersion(token, { + priorTo: args['prior-to'], + majorVersion: args.major, + })); + break; + } +} + +main().catch(e => { + // eslint-disable-next-line no-console + console.error(e); + process.exitCode = 1; +}); \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/bin/run-suite b/packages/@aws-cdk-testing/cli-integ/bin/run-suite new file mode 100755 index 0000000000000..d4a0aacaa4a54 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/bin/run-suite @@ -0,0 +1,2 @@ +#!/usr/bin/env node +require('./run-suite.js'); \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/bin/run-suite.ts b/packages/@aws-cdk-testing/cli-integ/bin/run-suite.ts new file mode 100644 index 0000000000000..46a19e44bf47b --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/bin/run-suite.ts @@ -0,0 +1,136 @@ +/* eslint-disable no-console */ +import * as path from 'path'; +// eslint-disable-next-line jest/no-jest-import +import * as jest from 'jest'; +import * as yargs from 'yargs'; +import { ReleasePackageSourceSetup } from '../lib/package-sources/release-source'; +import { RepoPackageSourceSetup, autoFindRoot } from '../lib/package-sources/repo-source'; +import { IPackageSourceSetup } from '../lib/package-sources/source'; +import { serializeForSubprocess } from '../lib/package-sources/subprocess'; + +async function main() { + const args = await yargs + .usage('$0 ') + .positional('SUITENAME', { + descripton: 'Name of the test suite to run', + type: 'string', + demandOption: true, + }) + .option('test', { + descripton: 'Test pattern to selectively run tests', + alias: 't', + type: 'string', + requiresArg: true, + }) + .option('use-source', { + descripton: 'Use TypeScript packages from the given source repository (or "auto")', + alias: 's', + type: 'string', + requiresArg: true, + }) + .option('use-cli-release', { + descripton: 'Run the current tests against the CLI at the given version', + alias: 'u', + type: 'string', + requiresArg: true, + }) + .option('auto-source', { + alias: 'a', + description: 'Automatically find the source tree from the current working directory', + type: 'boolean', + requiresArg: false, + }) + .option('runInBand', { + descripton: 'Run all tests in one Node process', + alias: 'i', + type: 'boolean', + }) + .options('framework-version', { + description: 'Framework version to use, if different than the CLI version (not all suites respect this)', + alias: 'f', + type: 'string', + }) + .options('verbose', { + alias: 'v', + description: 'Run in verbose mode', + type: 'boolean', + requiresArg: false, + }) + .options('passWithNoTests', { + description: 'Allow passing if the test suite is not found (default true when IS_CANARY mode, false otherwise)', + type: 'boolean', + requiresArg: false, + }) + .help() + .strictOptions() + .showHelpOnFail(false) + .argv; + + const suiteName = args._[0] as string; + if (!suiteName) { + throw new Error('Usage: run-suite '); + } + + let packageSource: undefined | IPackageSourceSetup; + function usePackageSource(s: IPackageSourceSetup) { + if (packageSource) { + throw new Error('Cannot specify two package sources'); + } + packageSource = s; + } + + if (args['use-source'] || args['auto-source']) { + if (args['framework-version']) { + throw new Error('Cannot use --framework-version with --use-source'); + } + + const root = args['use-source'] && args['use-source'] !== 'auto' + ? args['use-source'] + : await autoFindRoot(); + + usePackageSource(new RepoPackageSourceSetup(root)); + } else if (args['use-cli-release']) { + usePackageSource(new ReleasePackageSourceSetup(args['use-cli-release'], args['framework-version'])); + } + if (!packageSource) { + throw new Error('Specify either --use-source or --use-cli-release'); + } + + console.log(`Package source: ${packageSource.description}`); + console.log(`Test suite: ${suiteName}`); + + await packageSource.prepare(); + serializeForSubprocess(packageSource); + + if (args.verbose) { + process.env.VERBOSE = '1'; + } + + // Motivation behind this behavior: when adding a new test suite to the pipeline, because of the way our + // Pipeline package works, the suite would be added to the pipeline AND as a canary immediately. The canary + // would fail until the package was actually released, so for canaries we make an exception so that the initial + // canary would succeed even if the suite wasn't yet available. The fact that the suite is not optional in + // the pipeline protects us from typos. + const passWithNoTests = args.passWithNoTests ?? !!process.env.IS_CANARY; + + // Communicate with the config file (integ.jest.config.js) + process.env.TEST_SUITE_NAME = suiteName; + + try { + await jest.run([ + ...args.runInBand ? ['-i'] : [], + ...args.test ? ['-t', args.test] : [], + ...args.verbose ? ['--verbose'] : [], + ...passWithNoTests ? ['--passWithNoTests'] : [], + ], path.resolve(__dirname, '..', 'resources', 'integ.jest.config.js')); + + } finally { + await packageSource.cleanup(); + } +} + +main().catch(e => { + // eslint-disable-next-line no-console + console.error(e); + process.exitCode = 1; +}); diff --git a/packages/@aws-cdk-testing/cli-integ/bin/stage-distribution b/packages/@aws-cdk-testing/cli-integ/bin/stage-distribution new file mode 100755 index 0000000000000..99b7ad3606f7b --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/bin/stage-distribution @@ -0,0 +1,2 @@ +#!/usr/bin/env node +require('./stage-distribution.js'); diff --git a/packages/@aws-cdk-testing/cli-integ/bin/stage-distribution.ts b/packages/@aws-cdk-testing/cli-integ/bin/stage-distribution.ts new file mode 100644 index 0000000000000..5bc53c28caead --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/bin/stage-distribution.ts @@ -0,0 +1,259 @@ +/* eslint-disable no-console */ +import * as path from 'path'; +import * as fs from 'fs-extra'; +import * as glob from 'glob'; +import * as yargs from 'yargs'; +import { shell } from '../lib'; +import { TestRepository } from '../lib/staging/codeartifact'; +import { uploadJavaPackages, mavenLogin } from '../lib/staging/maven'; +import { uploadNpmPackages, npmLogin } from '../lib/staging/npm'; +import { uploadDotnetPackages, nugetLogin } from '../lib/staging/nuget'; +import { uploadPythonPackages, pypiLogin } from '../lib/staging/pypi'; +import { UsageDir } from '../lib/staging/usage-dir'; + +async function main() { + await yargs + .usage('$0 ') + .option('npm', { + description: 'Upload NPM packages only', + type: 'boolean', + requiresArg: false, + }) + .option('python', { + description: 'Upload Python packages only', + type: 'boolean', + requiresArg: false, + }) + .option('java', { + description: 'Upload Java packages only', + type: 'boolean', + requiresArg: false, + }) + .option('dotnet', { + description: 'Upload Dotnet packages only', + type: 'boolean', + requiresArg: false, + }) + .command('publish ', 'Publish a given directory', cmd => cmd + .positional('DIRECTORY', { + descripton: 'Directory distribution', + type: 'string', + demandOption: true, + }) + .option('name', { + alias: 'n', + description: 'Name of the repository to create (default: generate unique name)', + type: 'string', + requiresArg: true, + }), async (args) => { + + await validateDirectory(args); + const repo = await (args.name ? TestRepository.newWithName(args.name) : TestRepository.newRandom()); + const usageDir = UsageDir.default(); + + await doLogin(repo, usageDir, args); + await publish(repo, usageDir, args); + + header('Done'); + usageDir.advertise(); + }) + .command('login', 'Login to a given repository', cmd => cmd + .option('name', { + alias: 'n', + description: 'Name of the repository to log in to', + type: 'string', + requiresArg: true, + demandOption: true, + }), async (args) => { + + const repo = TestRepository.existing(args.name); + const usageDir = UsageDir.default(); + + await doLogin(repo, usageDir, args); + + usageDir.advertise(); + }) + .command('run ', 'Publish and run a command', cmd => cmd + .positional('DIRECTORY', { + descripton: 'Directory distribution', + type: 'string', + demandOption: true, + }) + .positional('COMMAND', { + alias: 'c', + description: 'Run the given command with the packages staged', + type: 'string', + array: true, + demandOption: true, + }) + .option('cleanup', { + alias: 'C', + description: 'Cleanup the repository afterwards', + type: 'boolean', + default: true, + requiresArg: false, + }), async (args) => { + + await validateDirectory(args); + const repo = await TestRepository.newRandom(); + const usageDir = UsageDir.default(); + + await doLogin(repo, usageDir, args); + await publish(repo, usageDir, args); + + try { + await usageDir.activateInCurrentProcess(); + + await shell(args.COMMAND ?? [], { + shell: true, + show: 'always', + }); + + } finally { + if (args.cleanup) { + await repo.delete(); + } + } + }) + .command('cleanup', 'Clean up testing repository', cmd => cmd + .option('name', { + alias: 'n', + description: 'Name of the repository to cleanup (default: most recent)', + type: 'string', + requiresArg: true, + }), async (args) => { + + const usageDir = UsageDir.default(); + + let repositoryName = args.name; + if (!repositoryName) { + repositoryName = (await usageDir.currentEnv()).CODEARTIFACT_REPO; + } + + if (!repositoryName) { + console.log(`No --name given and no $CODEARTIFACT_REPO found in ${usageDir.directory}, nothing cleaned up`); + return; + } + + const repo = TestRepository.existing(repositoryName); + await repo.delete(); + }) + .command('gc', 'Clean up day-old testing repositories', cmd => cmd, async () => { + await TestRepository.gc(); + }) + .demandCommand(1, 'You must supply a command') + .help() + .strictOptions() + .showHelpOnFail(false) + .parse(); +} + +async function validateDirectory(args: { + DIRECTORY: string, +}) { + if (!await fs.pathExists(path.join(args.DIRECTORY, 'build.json'))) { + throw new Error(`${args.DIRECTORY} does not look like a CDK dist directory (build.json missing)`); + } +} + +async function doLogin(repo: TestRepository, usageDir: UsageDir, args: { + npm?: boolean; + python?: boolean; + java?: boolean; + dotnet?: boolean; +}) { + const login = await repo.loginInformation(); + + const oldEnv = await usageDir.currentEnv(); + + await usageDir.clean(); + await usageDir.addToEnv({ + CODEARTIFACT_REPO: login.repositoryName, + }); + + if (oldEnv.BUILD_VERSION) { + await usageDir.addToEnv({ + BUILD_VERSION: oldEnv.BUILD_VERSION, + }); + } + + const doRepo = whichRepos(args); + + await doRepo.npm(() => npmLogin(login, usageDir)); + await doRepo.python(() => pypiLogin(login, usageDir)); + await doRepo.java(() => mavenLogin(login, usageDir)); + await doRepo.dotnet(() => nugetLogin(login, usageDir)); +} + +async function publish(repo: TestRepository, usageDir: UsageDir, args: { + DIRECTORY: string, + npm?: boolean; + python?: boolean; + java?: boolean; + dotnet?: boolean; +}) { + const directory = `${args.DIRECTORY}`; + const login = await repo.loginInformation(); + + const doRepo = whichRepos(args); + + const buildJson = await fs.readJson(path.join(directory, 'build.json')); + await usageDir.addToEnv({ + BUILD_VERSION: buildJson.version, + }); + + await doRepo.npm(async () => { + header('NPM'); + await uploadNpmPackages(glob.sync(path.join(directory, 'js', '*.tgz')), login, usageDir); + }); + + await doRepo.python(async () => { + header('Python'); + await uploadPythonPackages(glob.sync(path.join(directory, 'python', '*')), login); + }); + + await doRepo.java(async () => { + header('Java'); + await uploadJavaPackages(glob.sync(path.join(directory, 'java', '**', '*.pom')), login, usageDir); + }); + + await doRepo.dotnet(async () => { + header('.NET'); + await uploadDotnetPackages(glob.sync(path.join(directory, 'dotnet', '**', '*.nupkg')), usageDir); + }); + + console.log('🛍 Configuring packages for upstream versions'); + await repo.markAllUpstreamAllow(); +} + +function whichRepos(args: { + npm?: boolean; + python?: boolean; + java?: boolean; + dotnet?: boolean; +}) { + const all = args.npm === undefined && args.python === undefined && args.java === undefined && args.dotnet === undefined; + + const invoke = (block: () => Promise) => block(); + const skip = () => { }; + + return { + npm: args.npm || all ? invoke : skip, + python: args.python || all ? invoke : skip, + java: args.java || all ? invoke : skip, + dotnet: args.dotnet || all ? invoke : skip, + }; +} + +function header(caption: string) { + console.log(''); + console.log('/'.repeat(70)); + console.log(`// ${caption}`); + console.log(''); +} + +main().catch(e => { + // eslint-disable-next-line no-console + console.error(e); + process.exitCode = 1; +}); diff --git a/packages/@aws-cdk-testing/cli-integ/bin/test-root b/packages/@aws-cdk-testing/cli-integ/bin/test-root new file mode 100755 index 0000000000000..d14248e4d4019 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/bin/test-root @@ -0,0 +1,2 @@ +#!/usr/bin/env node +require('./test-root.js'); diff --git a/packages/@aws-cdk-testing/cli-integ/bin/test-root.ts b/packages/@aws-cdk-testing/cli-integ/bin/test-root.ts new file mode 100644 index 0000000000000..244194a7eb31c --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/bin/test-root.ts @@ -0,0 +1,3 @@ +import * as path from 'path'; +// eslint-disable-next-line no-console +console.log(path.resolve(__dirname, '..')); \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/entrypoints/test-cli-regression-against-current-code.sh b/packages/@aws-cdk-testing/cli-integ/entrypoints/test-cli-regression-against-current-code.sh new file mode 100755 index 0000000000000..ff50aa5f69a2b --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/entrypoints/test-cli-regression-against-current-code.sh @@ -0,0 +1,11 @@ +#!/bin/bash +# +# Run our integration tests in regression mode against the +# candidate version of the framework, which is the one we just packed. +# +set -euo pipefail +integdir=$(cd $(dirname $0) && pwd) + +source ${integdir}/test-cli-regression.bash + +run_regression_against_framework_version CANDIDATE_VERSION diff --git a/packages/@aws-cdk-testing/cli-integ/entrypoints/test-cli-regression-against-latest-release.sh b/packages/@aws-cdk-testing/cli-integ/entrypoints/test-cli-regression-against-latest-release.sh new file mode 100755 index 0000000000000..8b670eb7b793d --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/entrypoints/test-cli-regression-against-latest-release.sh @@ -0,0 +1,11 @@ +#!/bin/bash +# +# Run our integration tests in regression mode against the +# previous version of the framework, relative to the version being packed now. +# +set -euo pipefail +integdir=$(cd $(dirname $0) && pwd) + +source ${integdir}/test-cli-regression.bash + +run_regression_against_framework_version PREVIOUS_VERSION diff --git a/packages/aws-cdk/test/integ/test-cli-regression.bash b/packages/@aws-cdk-testing/cli-integ/entrypoints/test-cli-regression.bash similarity index 100% rename from packages/aws-cdk/test/integ/test-cli-regression.bash rename to packages/@aws-cdk-testing/cli-integ/entrypoints/test-cli-regression.bash diff --git a/packages/@aws-cdk-testing/cli-integ/entrypoints/test.sh b/packages/@aws-cdk-testing/cli-integ/entrypoints/test.sh new file mode 100755 index 0000000000000..bf0ec0a7c5c68 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/entrypoints/test.sh @@ -0,0 +1,12 @@ +#!/bin/bash +set -euo pipefail +scriptdir=$(cd $(dirname $0) && pwd) + +echo '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~' +echo 'CLI Integration Tests' +echo '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~' + +cd $scriptdir + +source ../common/jest-test.bash +invokeJest "$@" diff --git a/packages/@aws-cdk-testing/cli-integ/jest.config.js b/packages/@aws-cdk-testing/cli-integ/jest.config.js new file mode 100644 index 0000000000000..30ba8fce114e2 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/jest.config.js @@ -0,0 +1,10 @@ +const baseConfig = require('@aws-cdk/cdk-build-tools/config/jest.config'); +module.exports = { + ...baseConfig, + coverageThreshold: { + global: { + statements: 20, + branches: 2, + }, + }, +}; diff --git a/packages/aws-cdk/test/integ/helpers/aws.ts b/packages/@aws-cdk-testing/cli-integ/lib/aws.ts similarity index 99% rename from packages/aws-cdk/test/integ/helpers/aws.ts rename to packages/@aws-cdk-testing/cli-integ/lib/aws.ts index beea3fca64768..289b87bf955a1 100644 --- a/packages/aws-cdk/test/integ/helpers/aws.ts +++ b/packages/@aws-cdk-testing/cli-integ/lib/aws.ts @@ -232,14 +232,14 @@ retry.abort = (e: Error): Error => { return e; }; -export async function sleep(ms: number) { - return new Promise(ok => setTimeout(ok, ms)); -} - export function outputFromStack(key: string, stack: AWS.CloudFormation.Stack): string | undefined { return (stack.Outputs ?? []).find(o => o.OutputKey === key)?.OutputValue; } +export async function sleep(ms: number) { + return new Promise(ok => setTimeout(ok, ms)); +} + function chainableCredentials(region: string): AWS.Credentials | undefined { const profileName = process.env.AWS_PROFILE; @@ -287,5 +287,4 @@ function chainableCredentials(region: string): AWS.Credentials | undefined { } return undefined; - -} +} \ No newline at end of file diff --git a/packages/aws-cdk/test/integ/helpers/corking.ts b/packages/@aws-cdk-testing/cli-integ/lib/corking.ts similarity index 90% rename from packages/aws-cdk/test/integ/helpers/corking.ts rename to packages/@aws-cdk-testing/cli-integ/lib/corking.ts index c3970586ead03..f083270a028f5 100644 --- a/packages/aws-cdk/test/integ/helpers/corking.ts +++ b/packages/@aws-cdk-testing/cli-integ/lib/corking.ts @@ -25,4 +25,8 @@ export class MemoryStream extends stream.Writable { return new Promise(ok => strm.once('drain', ok)); } } + + public toString() { + return this.buffer().toString(); + } } diff --git a/packages/@aws-cdk-testing/cli-integ/lib/files.ts b/packages/@aws-cdk-testing/cli-integ/lib/files.ts new file mode 100644 index 0000000000000..186b1b0ff15f5 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/files.ts @@ -0,0 +1,81 @@ +import * as os from 'os'; +import * as path from 'path'; +import * as fs from 'fs-extra'; + +export async function rmFile(filename: string) { + if (await fs.pathExists(filename)) { + await fs.unlink(filename); + } +} + +export async function addToFile(filename: string, line: string) { + let contents = await fs.pathExists(filename) ? await fs.readFile(filename, { encoding: 'utf-8' }) : ''; + if (!contents.endsWith('\n')) { + contents += '\n'; + } + contents += line + '\n'; + + await writeFile(filename, contents); +} + +export async function writeFile(filename: string, contents: string) { + await fs.mkdirp(path.dirname(filename)); + await fs.writeFile(filename, contents, { encoding: 'utf-8' }); +} + +export async function copyDirectoryContents(dir: string, target: string) { + for (const file of await fs.readdir(path.join(dir), { encoding: 'utf-8' })) { + await fs.copyFile(path.join(dir, file), path.join(target, file)); + } +} + +export function findUp(name: string, directory: string = process.cwd()): string | undefined { + const absoluteDirectory = path.resolve(directory); + + const file = path.join(directory, name); + if (fs.existsSync(file)) { + return file; + } + + const { root } = path.parse(absoluteDirectory); + if (absoluteDirectory == root) { + return undefined; + } + + return findUp(name, path.dirname(absoluteDirectory)); +} + + +/** + * Docker-safe home directory + */ +export function homeDir() { + return os.userInfo().homedir ?? os.homedir(); +} + +export async function loadLines(filename: string): Promise { + return await fs.pathExists(filename) ? (await fs.readFile(filename, { encoding: 'utf-8' })).trim().split('\n') : []; +} + +export async function writeLines(filename: string, lines: string[]) { + // Must end in a newline or our bash script won't read it properly + await fs.writeFile(filename, lines.join('\n') + '\n', { encoding: 'utf-8' }); +} + +/** + * Update a spaceless ini file in place + */ +export function updateIniKey(lines: string[], key: string, value: string) { + const prefix = `${key}=`; + let found = false; + for (let i = 0; i < lines.length; i++) { + if (lines[i].startsWith(prefix)) { + lines[i] = prefix + value; + found = true; + break; + } + } + if (!found) { + lines.push(prefix + value); + } +} diff --git a/packages/@aws-cdk-testing/cli-integ/lib/github.ts b/packages/@aws-cdk-testing/cli-integ/lib/github.ts new file mode 100644 index 0000000000000..b483e5fb2fce8 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/github.ts @@ -0,0 +1,43 @@ +import { Octokit } from '@octokit/rest'; +import * as semver from 'semver'; + +export async function fetchPreviousVersion(token: string, options?: { + priorTo?: string, + majorVersion?: string, +}) { + const github = new Octokit({ auth: token }); + const releases = await github.repos.listReleases({ + owner: 'aws', + repo: 'aws-cdk', + }); + + // this returns a list in descending order, newest releases first + // opts for same major version where possible, falling back otherwise + // to previous major versions. + let previousMVRelease = undefined; + for (const release of releases.data) { + const version = release.name?.replace('v', ''); + if (!version) { continue; } + + // Any old version is fine + if (!options?.majorVersion && !options?.priorTo) { + return version; + } + + if (options?.majorVersion && `${semver.major(version)}` === options.majorVersion) { + return version; + } + + if (options?.priorTo && semver.lt(version, options?.priorTo) && semver.major(version) === semver.major(options.priorTo)) { + return version; + } + + // Otherwise return the most recent version that didn't match any + if (!previousMVRelease) { + previousMVRelease = version; + } + } + if (previousMVRelease) { return previousMVRelease; } + + throw new Error(`Unable to find previous version given ${JSON.stringify(options)}`); +}; \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/index.ts b/packages/@aws-cdk-testing/cli-integ/lib/index.ts new file mode 100644 index 0000000000000..32ab6ebcb83b4 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/index.ts @@ -0,0 +1,12 @@ +export * from './aws'; +export * from './corking'; +export * from './integ-test'; +export * from './memoize'; +export * from './resource-pool'; +export * from './with-sam'; +export * from './shell'; +export * from './with-aws'; +export * from './with-cdk-app'; +export * from './with-packages'; +export * from './with-temporary-directory'; +export * from './resources'; \ No newline at end of file diff --git a/packages/aws-cdk/test/integ/helpers/test-helpers.ts b/packages/@aws-cdk-testing/cli-integ/lib/integ-test.ts similarity index 61% rename from packages/aws-cdk/test/integ/helpers/test-helpers.ts rename to packages/@aws-cdk-testing/cli-integ/lib/integ-test.ts index 5dc65f6ed492e..e529591c50d1e 100644 --- a/packages/aws-cdk/test/integ/helpers/test-helpers.ts +++ b/packages/@aws-cdk-testing/cli-integ/lib/integ-test.ts @@ -2,9 +2,13 @@ import * as fs from 'fs'; import * as path from 'path'; import { MemoryStream } from './corking'; -const SKIP_TESTS = fs.readFileSync(path.join(__dirname, 'skip-tests.txt'), { encoding: 'utf-8' }).split('\n'); +const SKIP_TESTS = fs.readFileSync(path.join(__dirname, '..', 'skip-tests.txt'), { encoding: 'utf-8' }).split('\n'); -export type TestContext = { readonly output: NodeJS.WritableStream; }; +export interface TestContext { + readonly randomString: string; + readonly output: NodeJS.WritableStream; + log(s: string): void; +}; /** * A wrapper for jest's 'test' which takes regression-disabled tests into account and prints a banner @@ -31,19 +35,22 @@ export function integTest( output.write(`${name}\n`); output.write('================================================================\n'); - let success = true; try { - return await callback({ output }); + return await callback({ + output, + randomString: randomString(), + log(s: string) { + output.write(`${s}\n`); + }, + }); } catch (e) { - await output.flushTo(process.stderr); - process.stderr.write(`❌ ${e.toString()}\n`); - success = false; + output.write(e.message); + output.write(e.stack); + // Print output only if the test fails. Use 'console.log' so the output is buffered by + // jest and prints without a stack trace (if verbose: false). + // eslint-disable-next-line no-console + console.log(output.buffer().toString()); throw e; - } finally { - if (success) { - // Show people there's progress - process.stderr.write('✅'); - } } }, timeoutMillis); } @@ -51,3 +58,8 @@ export function integTest( function shouldSkip(testName: string) { return SKIP_TESTS.includes(testName); } + +export function randomString() { + // Crazy + return Math.random().toString(36).replace(/[^a-z0-9]+/g, ''); +} \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/lists.ts b/packages/@aws-cdk-testing/cli-integ/lib/lists.ts new file mode 100644 index 0000000000000..69f504a15474f --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/lists.ts @@ -0,0 +1,9 @@ +export function chunk(n: number, xs: A[]): A[][] { + const ret = new Array(); + + for (let i = 0; i < xs.length; i += n) { + ret.push(xs.slice(i, i + n)); + } + + return ret; +} \ No newline at end of file diff --git a/packages/aws-cdk/test/integ/helpers/memoize.ts b/packages/@aws-cdk-testing/cli-integ/lib/memoize.ts similarity index 100% rename from packages/aws-cdk/test/integ/helpers/memoize.ts rename to packages/@aws-cdk-testing/cli-integ/lib/memoize.ts diff --git a/packages/@aws-cdk-testing/cli-integ/lib/npm.ts b/packages/@aws-cdk-testing/cli-integ/lib/npm.ts new file mode 100644 index 0000000000000..991599f010ba8 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/npm.ts @@ -0,0 +1,13 @@ +import { spawnSync } from 'child_process'; + +const MINIMUM_VERSION = '3.9'; + +/** + * Use NPM preinstalled on the machine to look up a list of TypeScript versions + */ +export function typescriptVersionsSync(): string[] { + const { stdout } = spawnSync('npm', ['--silent', 'view', `typescript@>=${MINIMUM_VERSION}`, 'version', '--json']); + + const versions: string[] = JSON.parse(stdout); + return Array.from(new Set(versions.map(v => v.split('.').slice(0, 2).join('.')))); +} \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/package-sources/release-source.ts b/packages/@aws-cdk-testing/cli-integ/lib/package-sources/release-source.ts new file mode 100644 index 0000000000000..7d097630e26de --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/package-sources/release-source.ts @@ -0,0 +1,77 @@ +import * as os from 'os'; +import * as path from 'path'; +import * as fs from 'fs-extra'; +import { copyDirectoryContents } from '../files'; +import { shell, rimraf, addToShellPath } from '../shell'; +import { IPackageSourceSetup, IPackageSource } from './source'; + +export class ReleasePackageSourceSetup implements IPackageSourceSetup { + readonly name = 'release'; + readonly description = `release @ ${this.version}`; + + private tempDir?: string; + + constructor(private readonly version: string, private readonly frameworkVersion?: string) { + } + + public async prepare(): Promise { + this.tempDir = fs.mkdtempSync(path.join(os.tmpdir(), 'tmpcdk')); + fs.mkdirSync(this.tempDir, { recursive: true }); + + await shell(['node', require.resolve('npm'), 'install', `aws-cdk@${this.version}`], { + cwd: this.tempDir, + }); + + process.env.CDK_CLI_PATH = this.tempDir; + process.env.VERSION = this.version; + process.env.FRAMEWORK_VERSION = this.frameworkVersion ?? this.version; + } + + public async cleanup(): Promise { + if (this.tempDir) { + rimraf(this.tempDir); + } + } +} + +export class ReleasePackageSource implements IPackageSource { + private readonly cliPath: string; + private readonly version: string; + + constructor() { + this.cliPath = process.env.CDK_CLI_PATH!; + this.version = process.env.VERSION!; + } + + public async makeCliAvailable() { + addToShellPath(path.join(this.cliPath, 'node_modules', '.bin')); + } + + public assertJsiiPackagesAvailable() { + } + + public async initializeDotnetPackages(currentDir: string) { + if (process.env.CWD_FILES_DIR) { + await copyDirectoryContents(process.env.CWD_FILES_DIR, currentDir); + } + } + + public majorVersion() { + return this.version.split('.')[0] as string; + } + + public requestedFrameworkVersion() { + return process.env.FRAMEWORK_VERSION!; + } + + public requestedAlphaVersion(): string { + const frameworkVersion = this.requestedFrameworkVersion(); + if (frameworkVersion.includes('-rc.')) { + // For a pipeline release + return frameworkVersion.replace(/-rc\.\d+$/, '-alpha.999'); + } else { + // For a stable release + return `${frameworkVersion}-alpha.0`; + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/package-sources/repo-source.ts b/packages/@aws-cdk-testing/cli-integ/lib/package-sources/repo-source.ts new file mode 100644 index 0000000000000..d1d445d7bf931 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/package-sources/repo-source.ts @@ -0,0 +1,106 @@ +import * as os from 'os'; +import * as path from 'path'; +import * as fs from 'fs-extra'; +import { findUp } from '../files'; +import { shell, addToShellPath } from '../shell'; +import { IPackageSourceSetup, IPackageSource } from './source'; + +export class RepoPackageSourceSetup implements IPackageSourceSetup { + readonly name = 'repo'; + readonly description = `repo(${this.repoRoot})`; + + constructor(private readonly repoRoot: string) { + } + + public async prepare(): Promise { + if (!await fs.pathExists(path.join(this.repoRoot, 'package.json')) || !await fs.pathExists(path.join(this.repoRoot, 'yarn.lock'))) { + throw new Error(`${this.repoRoot}: does not look like the repository root`); + } + + process.env.REPO_ROOT = this.repoRoot; + process.env.REPO_PACKAGE_MAP = await writePackageMap(this.repoRoot); + addToShellPath(path.resolve(__dirname, 'repo-tools')); + } + + public async cleanup(): Promise { + } +} + +export class RepoPackageSource implements IPackageSource { + private readonly repoRoot: string; + + constructor() { + this.repoRoot = process.env.REPO_ROOT as string; + } + + public async makeCliAvailable() { + addToShellPath(path.join(this.repoRoot, 'packages', 'aws-cdk', 'bin')); + } + + public assertJsiiPackagesAvailable() { + throw new Error('jsii client packages are not available when using REPO source'); + } + + public async initializeDotnetPackages() { + } + + public majorVersion() { + const releaseJson = fs.readJsonSync(path.resolve(this.repoRoot, 'release.json')); + return releaseJson.majorVersion; + } + + public requestedFrameworkVersion(): string { + return '*'; + } + + public requestedAlphaVersion(): string { + return '*'; + } +} + +async function writePackageMap(repoRoot: string): Promise { + const packages = await findYarnPackages(repoRoot); + const fileName = path.join(os.tmpdir(), 'package-map.json'); + await fs.writeJson(fileName, packages); + return fileName; +} + +/** + * Cache monorepo discovery results, we only want to do this once per run + */ +const YARN_MONOREPO_CACHE: Record = {}; + +/** + * Return a { name -> directory } packages found in a Yarn monorepo + * + * Cached in YARN_MONOREPO_CACHE. + */ +async function findYarnPackages(root: string): Promise> { + if (!(root in YARN_MONOREPO_CACHE)) { + const output: YarnWorkspacesOutput = JSON.parse(await shell(['yarn', 'workspaces', '--silent', 'info'], { + captureStderr: false, + cwd: root, + show: 'error', + })); + + const ret: Record = {}; + for (const [k, v] of Object.entries(output)) { + ret[k] = path.join(root, v.location); + } + YARN_MONOREPO_CACHE[root] = ret; + } + return YARN_MONOREPO_CACHE[root]; +} + +/** + * Find the root directory of the repo from the current directory + */ +export async function autoFindRoot() { + const found = await findUp('release.json'); + if (!found) { + throw new Error(`Could not determine repository root: 'release.json' not found from ${process.cwd()}`); + } + return path.dirname(found); +} + +type YarnWorkspacesOutput = Record; diff --git a/packages/@aws-cdk-testing/cli-integ/lib/package-sources/repo-tools/npm b/packages/@aws-cdk-testing/cli-integ/lib/package-sources/repo-tools/npm new file mode 100644 index 0000000000000..ab3229febddc1 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/package-sources/repo-tools/npm @@ -0,0 +1,2 @@ +#!/usr/bin/env node +require('./npm.js'); \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/package-sources/repo-tools/npm.ts b/packages/@aws-cdk-testing/cli-integ/lib/package-sources/repo-tools/npm.ts new file mode 100644 index 0000000000000..5efcc3e4a865f --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/package-sources/repo-tools/npm.ts @@ -0,0 +1,48 @@ +import * as child_process from 'child_process'; +import * as fs from 'fs-extra'; + +let argv = process.argv.slice(2); + +// eslint-disable-next-line no-console +console.log('fake npm'); + +if (argv[0] === 'install') { + if (!process.env.REPO_PACKAGE_MAP) { + throw new Error('REPO_PACKAGE_MAP not set'); + } + const repoPackageMap = fs.readJsonSync(process.env.REPO_PACKAGE_MAP, { encoding: 'utf-8' }); + + // Replace paths in the 'package.json' in the current directory + if (fs.pathExistsSync('package.json')) { + const packageJson = fs.readJsonSync('package.json', { encoding: 'utf-8' }); + for (const deps of [packageJson.dependencies ?? {}, packageJson.devDependencies ?? {}]) { + for (const [name, version] of Object.entries(deps)) { + deps[name] = repoPackageMap[name] ?? version; + } + } + fs.writeJsonSync('package.json', packageJson, { encoding: 'utf-8' }); + } + + // Replace package names on the command line + argv = argv.map(x => repoPackageMap[x] ?? x); +} + +//////////////////////////////////////////////////////////////////////// +// Shell out to original npm + +const child = child_process.spawn('node', [require.resolve('npm'), ...argv], { + shell: false, + stdio: ['ignore', 'inherit', 'inherit'], +}); + +child.once('error', e => { + // eslint-disable-next-line no-console + console.error(e); + process.exitCode = 1; +}); + +child.once('close', code => { + if (code) { + process.exitCode = code; + } +}); \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/package-sources/source.ts b/packages/@aws-cdk-testing/cli-integ/lib/package-sources/source.ts new file mode 100644 index 0000000000000..21e970701db94 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/package-sources/source.ts @@ -0,0 +1,30 @@ +export interface IPackageSourceSetup { + readonly name: string; + readonly description: string; + + prepare(): Promise; + cleanup(): Promise; +} + +export interface IPackageSource { + makeCliAvailable(): Promise; + + assertJsiiPackagesAvailable(): void; + majorVersion(): string; + + initializeDotnetPackages(targetDir: string): Promise; + + /** + * Framework version if it's different than the CLI version + * + * Not all tests will respect this. + */ + requestedFrameworkVersion(): string; + + /** + * Versions of alpha packages if different than the CLI version + * + * Not all tests will respect this. + */ + requestedAlphaVersion(): string; +} \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/package-sources/subprocess.ts b/packages/@aws-cdk-testing/cli-integ/lib/package-sources/subprocess.ts new file mode 100644 index 0000000000000..09f8fdd231a0b --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/package-sources/subprocess.ts @@ -0,0 +1,15 @@ +import { ReleasePackageSource } from './release-source'; +import { RepoPackageSource } from './repo-source'; +import { IPackageSourceSetup, IPackageSource } from './source'; + +export function serializeForSubprocess(s: IPackageSourceSetup) { + process.env.PACKAGE_SOURCE = s.name; +} + +export function packageSourceInSubprocess(): IPackageSource { + switch (process.env.PACKAGE_SOURCE) { + case 'repo': return new RepoPackageSource(); + case 'release': return new ReleasePackageSource(); + default: throw new Error(`Unrecognized package source: ${process.env.PACKAGE_SOURCE}`); + } +} \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/resource-pool.ts b/packages/@aws-cdk-testing/cli-integ/lib/resource-pool.ts new file mode 100644 index 0000000000000..1c10f54be562d --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/resource-pool.ts @@ -0,0 +1,144 @@ +import { ILock, XpMutex, XpMutexPool } from './xpmutex'; + +/** + * A class that holds a pool of resources and gives them out and returns them on-demand + * + * The resources will be given out front to back, when they are returned + * the most recently returned version will be given out again (for best + * cache coherency). + * + * If there are multiple consumers waiting for a resource, consumers are serviced + * in FIFO order for most fairness. + */ +export class ResourcePool { + public static withResources(name: string, resources: A[]) { + const pool = XpMutexPool.fromName(name); + return new ResourcePool(pool, resources); + } + + private readonly resources: ReadonlyArray; + private readonly mutexes: Record = {}; + private readonly locks: Record = {}; + + private constructor(private readonly pool: XpMutexPool, resources: A[]) { + if (resources.length === 0) { + throw new Error('Must have at least one resource in the pool'); + } + + // Shuffle to reduce contention + resources = [...resources]; + fisherYatesShuffle(resources); + this.resources = resources; + + for (const res of resources) { + this.mutexes[res] = this.pool.mutex(res); + } + } + + /** + * Take one value from the resource pool + * + * If no such value is currently available, wait until it is. + */ + public async take(): Promise> { + while (true) { + // Start a wait on the unlock now -- if the unlock signal comes after + // we try to acquire but before we start the wait, we might miss it. + const wait = this.pool.awaitUnlock(5000); + + for (const res of this.unlockedResources()) { + const lease = await this.tryObtainLease(res); + if (lease) { + // Ignore the wait (count as handled) + wait.then(() => {}, () => {}); + return lease; + } + } + + // None available, wait until one gets unlocked then try again + await wait; + } + } + + /** + * Execute a block using a single resource from the pool + */ + public async using(block: (x: A) => B | Promise): Promise { + const lease = await this.take(); + try { + return await block(lease.value); + } finally { + await lease.dispose(); + } + } + + private async tryObtainLease(value: A) { + const lock = await this.mutexes[value].tryAcquire(); + if (!lock) { + return undefined; + } + + this.locks[value] = lock; + return this.makeLease(value); + } + + private makeLease(value: A): ILease { + let disposed = false; + return { + value, + dispose: () => { + if (disposed) { + throw new Error('Calling dispose() on an already-disposed lease.'); + } + disposed = true; + return this.returnValue(value); + }, + }; + } + + /** + * When a value is returned: + * + * - If someone's waiting for it, give it to them + * - Otherwise put it back into the pool + */ + private async returnValue(value: string) { + const lock = this.locks[value]; + delete this.locks[value]; + await lock?.release(); + } + + /** + * Return all resources that we definitely don't own the locks for + */ + private unlockedResources(): A[] { + return this.resources.filter(res => !this.locks[res]); + } +} + +/** + * A single value taken from the pool + */ +export interface ILease { + /** + * The value obtained by the lease + */ + readonly value: A; + + /** + * Return the leased value to the pool + */ + dispose(): Promise; +} + +/** + * Shuffle an array in-place + */ +function fisherYatesShuffle(xs: A[]) { + for (let i = xs.length - 1; i >= 1; i--) { + const j = Math.floor(Math.random() * i); + const h = xs[j]; + xs[j] = xs[i]; + xs[i] = h; + } +} diff --git a/packages/@aws-cdk-testing/cli-integ/lib/resources.ts b/packages/@aws-cdk-testing/cli-integ/lib/resources.ts new file mode 100644 index 0000000000000..39ab24ab48f58 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/resources.ts @@ -0,0 +1,4 @@ +import * as path from 'path'; + +export const RESOURCES_DIR = path.resolve(__dirname, '..', 'resources'); + diff --git a/packages/@aws-cdk-testing/cli-integ/lib/shell.ts b/packages/@aws-cdk-testing/cli-integ/lib/shell.ts new file mode 100644 index 0000000000000..a969f9d99fc11 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/shell.ts @@ -0,0 +1,168 @@ +import * as child_process from 'child_process'; +import * as fs from 'fs'; +import * as path from 'path'; +import { TestContext } from './integ-test'; +import { TemporaryDirectoryContext } from './with-temporary-directory'; + +/** + * A shell command that does what you want + * + * Is platform-aware, handles errors nicely. + */ +export async function shell(command: string[], options: ShellOptions = {}): Promise { + if (options.modEnv && options.env) { + throw new Error('Use either env or modEnv but not both'); + } + + // Always output the command + (options.output ?? process.stdout).write(`💻 ${command.join(' ')}\n`); + + let output: NodeJS.WritableStream | undefined = options.output ?? process.stdout; + switch (options.show ?? 'always') { + case 'always': + break; + case 'never': + case 'error': + output = undefined; + break; + } + + if (process.env.VERBOSE) { + output = process.stdout; + } + + const env = options.env ?? (options.modEnv ? { ...process.env, ...options.modEnv } : process.env); + + const child = child_process.spawn(command[0], command.slice(1), { + ...options, + env, + // Need this for Windows where we want .cmd and .bat to be found as well. + shell: true, + stdio: ['ignore', 'pipe', 'pipe'], + }); + + return new Promise((resolve, reject) => { + const stdout = new Array(); + const stderr = new Array(); + + child.stdout!.on('data', chunk => { + output?.write(chunk); + stdout.push(chunk); + }); + + child.stderr!.on('data', chunk => { + output?.write(chunk); + if (options.captureStderr ?? true) { + stderr.push(chunk); + } + }); + + child.once('error', reject); + + child.once('close', code => { + const stderrOutput = Buffer.concat(stderr).toString('utf-8'); + const stdoutOutput = Buffer.concat(stdout).toString('utf-8'); + const out = (options.onlyStderr ? stderrOutput : stdoutOutput + stderrOutput).trim(); + if (code === 0 || options.allowErrExit) { + resolve(out); + } else { + if (options.show === 'error') { + (options.output ?? process.stdout).write(out + '\n'); + } + reject(new Error(`'${command.join(' ')}' exited with error code ${code}.`)); + } + }); + }); +} + +export interface ShellOptions extends child_process.SpawnOptions { + /** + * Properties to add to 'env' + */ + readonly modEnv?: Record; + + /** + * Don't fail when exiting with an error + * + * @default false + */ + readonly allowErrExit?: boolean; + + /** + * Whether to capture stderr + * + * @default true + */ + readonly captureStderr?: boolean; + + /** + * Pass output here + * + * @default stdout unless quiet=true + */ + readonly output?: NodeJS.WritableStream; + + /** + * Only return stderr. For example, this is used to validate + * that when CI=true, all logs are sent to stdout. + * + * @default false + */ + readonly onlyStderr?: boolean; + + /** + * Don't log to stdout + * + * @default always + */ + readonly show?: 'always' | 'never' | 'error'; +} + +export class ShellHelper { + public static fromContext(context: TestContext & TemporaryDirectoryContext) { + return new ShellHelper(context.integTestDir, context.output); + } + + constructor( + private readonly _cwd: string, + private readonly _output: NodeJS.WritableStream) { } + + public async shell(command: string[], options: Omit = {}): Promise { + return shell(command, { + output: this._output, + cwd: this._cwd, + ...options, + }); + } +} + +/** + * rm -rf reimplementation, don't want to depend on an NPM package for this + */ +export function rimraf(fsPath: string) { + try { + const isDir = fs.lstatSync(fsPath).isDirectory(); + + if (isDir) { + for (const file of fs.readdirSync(fsPath)) { + rimraf(path.join(fsPath, file)); + } + fs.rmdirSync(fsPath); + } else { + fs.unlinkSync(fsPath); + } + } catch (e) { + // We will survive ENOENT + if (e.code !== 'ENOENT') { throw e; } + } +} + +export function addToShellPath(x: string) { + const parts = process.env.PATH?.split(':') ?? []; + + if (!parts.includes(x)) { + parts.unshift(x); + } + + process.env.PATH = parts.join(':'); +} \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/staging/codeartifact.ts b/packages/@aws-cdk-testing/cli-integ/lib/staging/codeartifact.ts new file mode 100644 index 0000000000000..75c00a97ad9f0 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/staging/codeartifact.ts @@ -0,0 +1,282 @@ +import * as AWS from 'aws-sdk'; +import { sleep } from '../aws'; + +const COLLECT_BY_TAG = 'collect-by'; +const REPO_LIFETIME_MS = 24 * 3600 * 1000; // One day + +export class TestRepository { + public static readonly DEFAULT_DOMAIN = 'test-cdk'; + + public static async newRandom() { + const qualifier = Math.random().toString(36).replace(/[^a-z0-9]+/g, ''); + + const repo = new TestRepository(`test-${qualifier}`); + await repo.prepare(); + return repo; + } + + public static async newWithName(name: string) { + const repo = new TestRepository(name); + await repo.prepare(); + return repo; + } + + public static existing(repositoryName: string) { + return new TestRepository(repositoryName); + } + + /** + * Garbage collect repositories + */ + public static async gc() { + if (!await TestRepository.existing('*dummy*').domainExists()) { + return; + } + + const codeArtifact = new AWS.CodeArtifact(); + + let nextToken: string | undefined; + do { + const page = await codeArtifact.listRepositories({ nextToken }).promise(); + + for (const repo of page.repositories ?? []) { + const tags = await codeArtifact.listTagsForResource({ resourceArn: repo.arn! }).promise(); + const collectable = tags?.tags?.find(t => t.key === COLLECT_BY_TAG && Number(t.value) < Date.now()); + if (collectable) { + // eslint-disable-next-line no-console + console.log('Deleting', repo.name); + await codeArtifact.deleteRepository({ + domain: repo.domainName!, + repository: repo.name!, + }).promise(); + } + } + + nextToken = page.nextToken; + } while (nextToken); + } + + public readonly npmUpstream = 'npm-upstream'; + public readonly pypiUpstream = 'pypi-upstream'; + public readonly nugetUpstream = 'nuget-upstream'; + public readonly mavenUpstream = 'maven-upstream'; + public readonly domain = TestRepository.DEFAULT_DOMAIN; + + private readonly codeArtifact = new AWS.CodeArtifact(); + + private _loginInformation: LoginInformation | undefined; + + private constructor(public readonly repositoryName: string) { + } + + public async prepare() { + await this.ensureDomain(); + await this.ensureUpstreams(); + + await this.ensureRepository(this.repositoryName, { + description: 'Testing repository', + upstreams: [ + this.npmUpstream, + this.pypiUpstream, + this.nugetUpstream, + this.mavenUpstream, + ], + tags: { + [COLLECT_BY_TAG]: `${Date.now() + REPO_LIFETIME_MS}`, + }, + }); + } + + public async loginInformation(): Promise { + if (this._loginInformation) { + return this._loginInformation; + } + + this._loginInformation = { + authToken: (await this.codeArtifact.getAuthorizationToken({ domain: this.domain, durationSeconds: 12 * 3600 }).promise()).authorizationToken!, + repositoryName: this.repositoryName, + npmEndpoint: (await this.codeArtifact.getRepositoryEndpoint({ domain: this.domain, repository: this.repositoryName, format: 'npm' }).promise()).repositoryEndpoint!, + mavenEndpoint: (await this.codeArtifact.getRepositoryEndpoint({ domain: this.domain, repository: this.repositoryName, format: 'maven' }).promise()).repositoryEndpoint!, + nugetEndpoint: (await this.codeArtifact.getRepositoryEndpoint({ domain: this.domain, repository: this.repositoryName, format: 'nuget' }).promise()).repositoryEndpoint!, + pypiEndpoint: (await this.codeArtifact.getRepositoryEndpoint({ domain: this.domain, repository: this.repositoryName, format: 'pypi' }).promise()).repositoryEndpoint!, + }; + return this._loginInformation; + } + + public async delete() { + try { + await this.codeArtifact.deleteRepository({ + domain: this.domain, + repository: this.repositoryName, + }).promise(); + + // eslint-disable-next-line no-console + console.log('Deleted', this.repositoryName); + } catch (e) { + if (e.code !== 'ResourceNotFoundException') { throw e; } + // Okay + } + } + + /** + * List all packages and mark them as "allow upstream versions". + * + * If we don't do this and we publish `foo@2.3.4-rc.0`, then we can't + * download `foo@2.3.0` anymore because by default CodeArtifact will + * block different versions from the same package. + */ + public async markAllUpstreamAllow() { + for await (const pkg of this.listPackages({ upstream: 'BLOCK' })) { + await retryThrottled(() => this.codeArtifact.putPackageOriginConfiguration({ + domain: this.domain, + repository: this.repositoryName, + + format: pkg.format!, + package: pkg.package!, + namespace: pkg.namespace!, + restrictions: { + publish: 'ALLOW', + upstream: 'ALLOW', + }, + }).promise()); + } + } + + private async ensureDomain() { + if (await this.domainExists()) { return; } + await this.codeArtifact.createDomain({ + domain: this.domain, + tags: [{ key: 'testing', value: 'true' }], + }).promise(); + } + + private async ensureUpstreams() { + await this.ensureRepository(this.npmUpstream, { + description: 'The upstream repository for NPM', + external: 'public:npmjs', + }); + await this.ensureRepository(this.mavenUpstream, { + description: 'The upstream repository for Maven', + external: 'public:maven-central', + }); + await this.ensureRepository(this.nugetUpstream, { + description: 'The upstream repository for NuGet', + external: 'public:nuget-org', + }); + await this.ensureRepository(this.pypiUpstream, { + description: 'The upstream repository for PyPI', + external: 'public:pypi', + }); + } + + private async ensureRepository(name: string, options?: { + readonly description?: string, + readonly external?: string, + readonly upstreams?: string[], + readonly tags?: Record, + }) { + if (await this.repositoryExists(name)) { return; } + + await this.codeArtifact.createRepository({ + domain: this.domain, + repository: name, + description: options?.description, + upstreams: options?.upstreams?.map(repositoryName => ({ repositoryName })), + tags: options?.tags ? Object.entries(options.tags).map(([key, value]) => ({ key, value })) : undefined, + }).promise(); + + if (options?.external) { + const externalConnection = options.external; + await retry(() => this.codeArtifact.associateExternalConnection({ + domain: this.domain, + repository: name, + externalConnection, + }).promise()); + } + } + + private async domainExists() { + try { + await this.codeArtifact.describeDomain({ domain: this.domain }).promise(); + return true; + } catch (e) { + if (e.code !== 'ResourceNotFoundException') { throw e; } + return false; + } + } + + private async repositoryExists(name: string) { + try { + await this.codeArtifact.describeRepository({ domain: this.domain, repository: name }).promise(); + return true; + } catch (e) { + if (e.code !== 'ResourceNotFoundException') { throw e; } + return false; + } + } + + private async* listPackages(filter: Pick = {}) { + let response = await retryThrottled(() => this.codeArtifact.listPackages({ + domain: this.domain, + repository: this.repositoryName, + ...filter, + }).promise()); + + while (true) { + for (const p of response.packages ?? []) { + yield p; + } + + if (!response.nextToken) { + break; + } + + response = await retryThrottled(() => this.codeArtifact.listPackages({ + domain: this.domain, + repository: this.repositoryName, + ...filter, + nextToken: response.nextToken, + }).promise()); + } + } +} + +async function retry(block: () => Promise) { + let attempts = 3; + while (true) { + try { + return await block(); + } catch (e) { + if (attempts-- === 0) { throw e; } + // eslint-disable-next-line no-console + console.debug(e.message); + await sleep(500); + } + } +} + +async function retryThrottled(block: () => Promise) { + let time = 100; + let attempts = 15; + while (true) { + try { + return await block(); + } catch (e) { + // eslint-disable-next-line no-console + console.debug(e.message); + if (e.code !== 'ThrottlingException') { throw e; } + if (attempts-- === 0) { throw e; } + await sleep(Math.floor(Math.random() * time)); + time *= 2; + } + } +} + +export interface LoginInformation { + readonly authToken: string; + readonly repositoryName: string; + readonly npmEndpoint: string; + readonly mavenEndpoint: string; + readonly nugetEndpoint: string; + readonly pypiEndpoint: string; +} \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/staging/maven.ts b/packages/@aws-cdk-testing/cli-integ/lib/staging/maven.ts new file mode 100644 index 0000000000000..18bb6a83f1255 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/staging/maven.ts @@ -0,0 +1,87 @@ +/* eslint-disable no-console */ +import * as path from 'path'; +import { writeFile } from '../files'; +import { shell } from '../shell'; +import { LoginInformation } from './codeartifact'; +import { parallelShell } from './parallel-shell'; +import { UsageDir } from './usage-dir'; + +// Do not try to JIT the Maven binary +const NO_JIT = '-XX:+TieredCompilation -XX:TieredStopAtLevel=1'; + +export async function mavenLogin(login: LoginInformation, usageDir: UsageDir) { + await writeMavenSettingsFile(settingsFile(usageDir), login); + + // Write env var + // Twiddle JVM settings a bit to make Maven survive running on a CodeBuild box. + await usageDir.addToEnv({ + MAVEN_OPTS: `-Duser.home=${usageDir.directory} ${NO_JIT} ${process.env.MAVEN_OPTS ?? ''}`.trim(), + }); +} + +function settingsFile(usageDir: UsageDir) { + // If we configure usageDir as a fake home directory Maven will find this file. + // (No other way to configure the settings file as part of the environment). + return path.join(usageDir.directory, '.m2', 'settings.xml'); +} + +export async function uploadJavaPackages(packages: string[], login: LoginInformation, usageDir: UsageDir) { + await parallelShell(packages, async (pkg, output) => { + console.log(`⏳ ${pkg}`); + + await shell(['mvn', + `--settings=${settingsFile(usageDir)}`, + 'org.apache.maven.plugins:maven-deploy-plugin:3.0.0:deploy-file', + `-Durl=${login.mavenEndpoint}`, + '-DrepositoryId=codeartifact', + `-DpomFile=${pkg}`, + `-Dfile=${pkg.replace(/.pom$/, '.jar')}`, + `-Dsources=${pkg.replace(/.pom$/, '-sources.jar')}`, + `-Djavadoc=${pkg.replace(/.pom$/, '-javadoc.jar')}`], { + output, + modEnv: { + // Do not try to JIT the Maven binary + MAVEN_OPTS: `${NO_JIT} ${process.env.MAVEN_OPTS ?? ''}`.trim(), + }, + }); + + console.log(`✅ ${pkg}`); + }, + (pkg, output) => { + if (output.toString().includes('409 Conflict')) { + console.log(`❌ ${pkg}: already exists. Skipped.`); + return 'skip'; + } + return 'fail'; + }); +} + +export async function writeMavenSettingsFile(filename: string, login: LoginInformation) { + await writeFile(filename, ` + + + + codeartifact + aws + ${login.authToken} + + + + + default + + + codeartifact + ${login.mavenEndpoint} + + + + + + default + + `); +} diff --git a/packages/@aws-cdk-testing/cli-integ/lib/staging/npm.ts b/packages/@aws-cdk-testing/cli-integ/lib/staging/npm.ts new file mode 100644 index 0000000000000..74db6eddc76a5 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/staging/npm.ts @@ -0,0 +1,62 @@ +/* eslint-disable no-console */ +import * as path from 'path'; +import { updateIniKey, loadLines, writeLines } from '../files'; +import { shell } from '../shell'; +import { LoginInformation } from './codeartifact'; +import { parallelShell } from './parallel-shell'; +import { UsageDir } from './usage-dir'; + +export async function npmLogin(login: LoginInformation, usageDir: UsageDir) { + // Creating an ~/.npmrc that references an envvar is what you're supposed to do. (https://docs.npmjs.com/private-modules/ci-server-config) + await writeNpmLoginToken(usageDir, login.npmEndpoint, '${NPM_TOKEN}'); + + // Add variables to env file + await usageDir.addToEnv(npmEnv(usageDir, login)); +} + +function npmEnv(usageDir: UsageDir, login: LoginInformation) { + return { + npm_config_userconfig: path.join(usageDir.directory, '.npmrc'), + npm_config_registry: login.npmEndpoint, + npm_config_always_auth: 'true', // Necessary for NPM 6, otherwise it will sometimes not pass the token + NPM_TOKEN: login.authToken, + }; +} + +export async function uploadNpmPackages(packages: string[], login: LoginInformation, usageDir: UsageDir) { + await parallelShell(packages, async (pkg, output) => { + console.log(`⏳ ${pkg}`); + + // path.resolve() is required -- if the filename ends up looking like `js/bla.tgz` then NPM thinks it's a short form GitHub name. + await shell(['node', require.resolve('npm'), 'publish', path.resolve(pkg)], { + modEnv: npmEnv(usageDir, login), + show: 'error', + output, + }); + + console.log(`✅ ${pkg}`); + }, (pkg, output) => { + if (output.toString().includes('code EPUBLISHCONFLICT')) { + console.log(`❌ ${pkg}: already exists. Skipped.`); + return 'skip'; + } + if (output.toString().includes('code EPRIVATE')) { + console.log(`❌ ${pkg}: is private. Skipped.`); + return 'skip'; + } + return 'fail'; + }); +} + +async function writeNpmLoginToken(usageDir: UsageDir, endpoint: string, token: string) { + const rcFile = path.join(usageDir.directory, '.npmrc'); + const lines = await loadLines(rcFile); + + const key = `${endpoint.replace(/^https:/, '')}:_authToken`; + updateIniKey(lines, key, token); + + await writeLines(rcFile, lines); + return rcFile; +} + +// Environment variable, .npmrc in same directory as package.json or in home dir \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/staging/nuget.ts b/packages/@aws-cdk-testing/cli-integ/lib/staging/nuget.ts new file mode 100644 index 0000000000000..91b4cde286f64 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/staging/nuget.ts @@ -0,0 +1,75 @@ +/* eslint-disable no-console */ +import { writeFile } from '../files'; +import { shell } from '../shell'; +import { LoginInformation } from './codeartifact'; +import { parallelShell } from './parallel-shell'; +import { UsageDir } from './usage-dir'; + +export async function nugetLogin(login: LoginInformation, usageDir: UsageDir) { + // NuGet.Config MUST live in the current directory or in the home directory, and there is no environment + // variable to configure its location. + await writeNuGetConfigFile(usageDir.cwdFile('NuGet.Config'), login); +} + +export async function uploadDotnetPackages(packages: string[], usageDir: UsageDir) { + await usageDir.copyCwdFileHere('NuGet.Config'); + + await parallelShell(packages, async (pkg, output) => { + console.log(`⏳ ${pkg}`); + + await shell(['dotnet', 'nuget', 'push', + pkg, + '--source', 'CodeArtifact', + '--no-symbols', + '--force-english-output', + '--disable-buffering', + '--timeout', '600', + '--skip-duplicate'], { + output, + }); + + console.log(`✅ ${pkg}`); + }, + (pkg, output) => { + if (output.toString().includes('Conflict')) { + console.log(`❌ ${pkg}: already exists. Skipped.`); + return 'skip'; + } + if (output.includes('System.Threading.AbandonedMutexException')) { + console.log(`♻️ ${pkg}: AbandonedMutexException. Probably a sign of throttling, retrying.`); + return 'retry'; + } + if (output.includes('Too Many Requests')) { + console.log(`♻️ ${pkg}: Too many requests. Retrying.`); + return 'retry'; + } + if (output.includes('System.IO.IOException: The system cannot open the device or file specified.')) { + console.log(`♻️ ${pkg}: Some error that we've seen before as a result of throttling. Retrying.`); + return 'retry'; + } + return 'fail'; + }); +} + +async function writeNuGetConfigFile(filename: string, login: LoginInformation) { + // `dotnet nuget push` has an `--api-key` parameter, but CodeArtifact + // does not support that. We must authenticate with Basic auth. + await writeFile(filename, ` + + + + + + + + + + + + + + +`); +} + +// NuGet.Config in current directory \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/staging/parallel-shell.ts b/packages/@aws-cdk-testing/cli-integ/lib/staging/parallel-shell.ts new file mode 100644 index 0000000000000..53242e73a1239 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/staging/parallel-shell.ts @@ -0,0 +1,52 @@ +import PQueue from 'p-queue'; +import { sleep } from '../aws'; +import { MemoryStream } from '../corking'; + + +export type ErrorResponse = 'fail' | 'skip' | 'retry'; + +/** + * Run a function in parallel with cached output + */ +export async function parallelShell( + inputs: A[], + block: (x: A, output: NodeJS.WritableStream) => Promise, + swallowError?: (x: A, output: string) => ErrorResponse, +) { + // Limit to 10 for now, too many instances of Maven exhaust the CodeBuild instance memory + const q = new PQueue({ concurrency: Number(process.env.CONCURRENCY) || 10 }); + await q.addAll(inputs.map(input => async () => { + let attempts = 10; + let sleepMs = 500; + while (true) { + const output = new MemoryStream(); + try { + await block(input, output); + return; + } catch (e) { + switch (swallowError?.(input, output.toString())) { + case 'skip': + return; + + case 'retry': + if (--attempts > 0) { + await sleep(Math.floor(Math.random() * sleepMs)); + sleepMs *= 2; + continue; + } + break; + + case 'fail': + case undefined: + break; + } + + // eslint-disable-next-line no-console + console.error(output.toString()); + throw e; + } + } + })); + + await q.onEmpty(); +} \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/staging/pypi.ts b/packages/@aws-cdk-testing/cli-integ/lib/staging/pypi.ts new file mode 100644 index 0000000000000..6308a95ce3b5b --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/staging/pypi.ts @@ -0,0 +1,50 @@ +/* eslint-disable no-console */ +import * as path from 'path'; +import { writeFile } from '../files'; +import { shell } from '../shell'; +import { LoginInformation } from './codeartifact'; +import { parallelShell } from './parallel-shell'; +import { UsageDir } from './usage-dir'; + +export async function pypiLogin(login: LoginInformation, usageDir: UsageDir) { + // Write pip config file and set environment var + await writeFile(path.join(usageDir.directory, 'pip.conf'), [ + '[global]', + `index-url = https://aws:${login.authToken}@${login.pypiEndpoint.replace(/^https:\/\//, '')}simple/`, + ].join('\n')); + await usageDir.addToEnv({ + PIP_CONFIG_FILE: `${usageDir.directory}/pip.conf`, + }); +} + +export async function uploadPythonPackages(packages: string[], login: LoginInformation) { + await shell(['pip', 'install', 'twine'], { show: 'error' }); + + // Even though twine supports uploading all packages in one go, we have to upload them + // individually since CodeArtifact does not support Twine's `--skip-existing`. Fun beans. + await parallelShell(packages, async (pkg, output) => { + console.log(`⏳ ${pkg}`); + + await shell(['twine', 'upload', '--verbose', pkg], { + modEnv: { + TWINE_USERNAME: 'aws', + TWINE_PASSWORD: login.authToken, + TWINE_REPOSITORY_URL: login.pypiEndpoint, + }, + show: 'error', + output, + }); + + console.log(`✅ ${pkg}`); + }, (pkg, output) => { + if (output.toString().includes('This package is configured to block new versions') || output.toString().includes('409 Conflict')) { + console.log(`❌ ${pkg}: already exists. Skipped.`); + return 'skip'; + } + if (output.includes('429 Too Many Requests ')) { + console.log(`♻️ ${pkg}: 429 Too Many Requests. Retrying.`); + return 'retry'; + } + return 'fail'; + }); +} \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/staging/usage-dir.ts b/packages/@aws-cdk-testing/cli-integ/lib/staging/usage-dir.ts new file mode 100644 index 0000000000000..055d85f875cb8 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/staging/usage-dir.ts @@ -0,0 +1,99 @@ +import * as path from 'path'; +import * as fs from 'fs-extra'; +import { copyDirectoryContents, homeDir, loadLines, updateIniKey, writeLines } from '../files'; + +export const DEFAULT_USAGE_DIR = path.join(homeDir(), '.codeartifact/usage'); + +/** + * The usage directory is where we write per-session config files to access the CodeArtifact repository. + * + * Some config files may be written in a system-global location, but they will not be active unless the + * contents of this directory have been sourced/copied into the current terminal. + * + * CONTRACT + * + * There are two special entries: + * + * - `env`, a file with `key=value` entries for environment variables to set. + * - `cwd/`, a directory with files that need to be copied into the current directory before each command. + * + * Other than these, code may write tempfiles to this directory if it wants, but there is no meaning + * implied for other files. + */ +export class UsageDir { + public static default() { + return new UsageDir(DEFAULT_USAGE_DIR); + } + + public readonly envFile: string; + public readonly cwdDir: string; + + private constructor(public readonly directory: string) { + this.envFile = path.join(this.directory, 'env'); + this.cwdDir = path.join(this.directory, 'cwd'); + } + + public async clean() { + await fs.rm(this.directory, { recursive: true, force: true }); + await fs.mkdirp(path.join(this.directory, 'cwd')); + await fs.writeFile(path.join(this.directory, 'env'), '', { encoding: 'utf-8' }); + + await this.addToEnv({ + CWD_FILES_DIR: path.join(this.directory, 'cwd'), + }); + + // Write a bash helper to load these settings + await fs.writeFile(path.join(this.directory, 'activate.bash'), [ + `while read -u10 line; do [[ -z $line ]] || export "$line"; done 10<${this.directory}/env`, + 'cp -R $CWD_FILES_DIR/ .', // Copy files from directory even if it is empty + ].join('\n'), { encoding: 'utf-8' }); + } + + public async addToEnv(settings: Record) { + const lines = await loadLines(this.envFile); + for (const [k, v] of Object.entries(settings)) { + updateIniKey(lines, k, v); + } + await writeLines(this.envFile, lines); + } + + public async currentEnv(): Promise> { + const lines = await loadLines(this.envFile); + + const splitter = /^([a-zA-Z0-9_-]+)\s*=\s*(.*)$/; + + const ret: Record = {}; + for (const line of lines) { + const m = line.match(splitter); + if (m) { + ret[m[1]] = m[2]; + } + } + return ret; + } + + public cwdFile(filename: string) { + return path.join(this.cwdDir, filename); + } + + public async activateInCurrentProcess() { + for (const [k, v] of Object.entries(await this.currentEnv())) { + process.env[k] = v; + } + + await copyDirectoryContents(this.cwdDir, '.'); + } + + public async copyCwdFileHere(...filenames: string[]) { + for (const file of filenames) { + await fs.copyFile(path.join(this.cwdDir, file), file); + } + } + + public advertise() { + // eslint-disable-next-line no-console + console.log('To activate these settings in the current terminal:'); + // eslint-disable-next-line no-console + console.log(` source ${this.directory}/activate.bash`); + } +} \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/lib/with-aws.ts b/packages/@aws-cdk-testing/cli-integ/lib/with-aws.ts new file mode 100644 index 0000000000000..a18b6d6db4af4 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/with-aws.ts @@ -0,0 +1,63 @@ +import { AwsClients } from './aws'; +import { TestContext } from './integ-test'; +import { ResourcePool } from './resource-pool'; + +export type AwsContext = { readonly aws: AwsClients }; + +/** + * Higher order function to execute a block with an AWS client setup + * + * Allocate the next region from the REGION pool and dispose it afterwards. + */ +export function withAws(block: (context: A & AwsContext) => Promise) { + return (context: A) => regionPool().using(async (region) => { + const aws = await AwsClients.forRegion(region, context.output); + await sanityCheck(aws); + + return block({ ...context, aws }); + }); +} + +let _regionPool: undefined | ResourcePool; +export function regionPool(): ResourcePool { + if (_regionPool !== undefined) { + return _regionPool; + } + + const REGIONS = process.env.AWS_REGIONS + ? process.env.AWS_REGIONS.split(',') + : [process.env.AWS_REGION ?? process.env.AWS_DEFAULT_REGION ?? 'us-east-1']; + + // eslint-disable-next-line no-console + console.log(`Using regions: ${REGIONS}\n`); + + _regionPool = ResourcePool.withResources('aws_regions', REGIONS); + return _regionPool; +} + +/** + * Perform a one-time quick sanity check that the AWS clients have properly configured credentials + * + * If we don't do this, calls are going to fail and they'll be retried and everything will take + * forever before the user notices a simple misconfiguration. + * + * We can't check for the presence of environment variables since credentials could come from + * anywhere, so do simple account retrieval. + * + * Only do it once per process. + */ +async function sanityCheck(aws: AwsClients) { + if (sanityChecked === undefined) { + try { + await aws.account(); + sanityChecked = true; + } catch (e) { + sanityChecked = false; + throw new Error(`AWS credentials probably not configured, got error: ${e.message}`); + } + } + if (!sanityChecked) { + throw new Error('AWS credentials probably not configured, see previous error'); + } +} +let sanityChecked: boolean | undefined; \ No newline at end of file diff --git a/packages/aws-cdk/test/integ/helpers/cdk.ts b/packages/@aws-cdk-testing/cli-integ/lib/with-cdk-app.ts similarity index 65% rename from packages/aws-cdk/test/integ/helpers/cdk.ts rename to packages/@aws-cdk-testing/cli-integ/lib/with-cdk-app.ts index 6b95f2d5d44f1..efc14dbaf17c0 100644 --- a/packages/aws-cdk/test/integ/helpers/cdk.ts +++ b/packages/@aws-cdk-testing/cli-integ/lib/with-cdk-app.ts @@ -1,80 +1,14 @@ -import * as child_process from 'child_process'; +/* eslint-disable no-console */ import * as fs from 'fs'; import * as os from 'os'; import * as path from 'path'; import { outputFromStack, AwsClients } from './aws'; -import { memoize0 } from './memoize'; -import { ResourcePool } from './resource-pool'; -import { TestContext } from './test-helpers'; - -const REGIONS = process.env.AWS_REGIONS - ? process.env.AWS_REGIONS.split(',') - : [process.env.AWS_REGION ?? process.env.AWS_DEFAULT_REGION ?? 'us-east-1']; - -export const FRAMEWORK_VERSION = process.env.FRAMEWORK_VERSION ?? '*'; - -export let MAJOR_VERSION = FRAMEWORK_VERSION.split('.')[0]; -if (MAJOR_VERSION === '*') { - if (process.env.REPO_ROOT) { - // eslint-disable-next-line @typescript-eslint/no-require-imports - const releaseJson = require(path.resolve(process.env.REPO_ROOT, 'release.json')); - MAJOR_VERSION = `${releaseJson.majorVersion}`; - } else { - // eslint-disable-next-line no-console - console.error('[WARNING] Have to guess at major version. Guessing version 1 to not break anything, but this should not happen'); - MAJOR_VERSION = '1'; - } -} - -process.stdout.write(`Using regions: ${REGIONS}\n`); -process.stdout.write(`Using framework version: ${FRAMEWORK_VERSION} (major version ${MAJOR_VERSION})\n`); - -const REGION_POOL = new ResourcePool(REGIONS); - - -/** - * Cache monorepo discovery results, we only want to do this once per run - */ -const YARN_MONOREPO_CACHE: Record = {}; - -/** - * Return a { name -> directory } packages found in a Yarn monorepo - * - * Cached in YARN_MONOREPO_CACHE. - */ -export async function findYarnPackages(root: string): Promise> { - if (!(root in YARN_MONOREPO_CACHE)) { - const output: YarnWorkspacesOutput = JSON.parse(await shell(['yarn', 'workspaces', '--silent', 'info'], { - captureStderr: false, - cwd: root, - })); - - const ret: Record = {}; - for (const [k, v] of Object.entries(output)) { - ret[k] = path.join(root, v.location); - } - YARN_MONOREPO_CACHE[root] = ret; - } - return YARN_MONOREPO_CACHE[root]; -} - -type YarnWorkspacesOutput = Record; - -export type AwsContext = { readonly aws: AwsClients }; - -/** - * Higher order function to execute a block with an AWS client setup - * - * Allocate the next region from the REGION pool and dispose it afterwards. - */ -export function withAws(block: (context: A & AwsContext) => Promise) { - return (context: A) => REGION_POOL.using(async (region) => { - const aws = await AwsClients.forRegion(region, context.output); - await sanityCheck(aws); - - return block({ ...context, aws }); - }); -} +import { TestContext } from './integ-test'; +import { IPackageSource } from './package-sources/source'; +import { packageSourceInSubprocess } from './package-sources/subprocess'; +import { RESOURCES_DIR } from './resources'; +import { shell, ShellOptions, ShellHelper, rimraf } from './shell'; +import { AwsContext, withAws } from './with-aws'; /** * Higher order function to execute a block with a CDK app fixture @@ -86,7 +20,7 @@ export function withAws(block: (context: A & AwsContext) */ export function withCdkApp(block: (context: TestFixture) => Promise) { return async (context: A) => { - const randy = randomString(); + const randy = context.randomString; const stackNamePrefix = `cdktest-${randy}`; const integTestDir = path.join(os.tmpdir(), `cdk-integ-${randy}`); @@ -94,18 +28,19 @@ export function withCdkApp(block: (context: context.output.write(` Test directory: ${integTestDir}\n`); context.output.write(` Region: ${context.aws.region}\n`); - await cloneDirectory(path.join(__dirname, '..', 'cli', 'app'), integTestDir, context.output); + await cloneDirectory(path.join(RESOURCES_DIR, 'cdk-apps', 'app'), integTestDir, context.output); const fixture = new TestFixture( integTestDir, stackNamePrefix, context.output, - context.aws); + context.aws, + context.randomString); let success = true; try { - const installationVersion = FRAMEWORK_VERSION; + const installationVersion = fixture.packages.requestedFrameworkVersion(); - if (MAJOR_VERSION === '1') { + if (fixture.packages.majorVersion() === '1') { await installNpmPackages(fixture, { '@aws-cdk/core': installationVersion, '@aws-cdk/aws-sns': installationVersion, @@ -134,7 +69,7 @@ export function withCdkApp(block: (context: throw e; } finally { if (process.env.INTEG_NO_CLEAN) { - process.stderr.write(`Left test directory in '${integTestDir}' ($INTEG_NO_CLEAN)\n`); + context.log(`Left test directory in '${integTestDir}' ($INTEG_NO_CLEAN)\n`); } else { await fixture.dispose(success); } @@ -149,7 +84,7 @@ export function withMonolithicCfnIncludeCdkApp(block: (co throw new Error('The UBERPACKAGE environment variable is required for running this test!'); } - const randy = randomString(); + const randy = context.randomString; const stackNamePrefix = `cdk-uber-cfn-include-${randy}`; const integTestDir = path.join(os.tmpdir(), `cdk-uber-cfn-include-${randy}`); @@ -157,18 +92,19 @@ export function withMonolithicCfnIncludeCdkApp(block: (co context.output.write(` Test directory: ${integTestDir}\n`); const awsClients = await AwsClients.default(context.output); - await cloneDirectory(path.join(__dirname, '..', 'uberpackage', 'cfn-include-app'), integTestDir, context.output); + await cloneDirectory(path.join(RESOURCES_DIR, 'cdk-apps', 'cfn-include-app'), integTestDir, context.output); const fixture = new TestFixture( integTestDir, stackNamePrefix, context.output, awsClients, + context.randomString, ); let success = true; try { await installNpmPackages(fixture, { - [uberPackage]: FRAMEWORK_VERSION ?? '*', + [uberPackage]: fixture.packages.requestedFrameworkVersion(), }); await block(fixture); @@ -177,7 +113,7 @@ export function withMonolithicCfnIncludeCdkApp(block: (co throw e; } finally { if (process.env.INTEG_NO_CLEAN) { - process.stderr.write(`Left test directory in '${integTestDir}' ($INTEG_NO_CLEAN)\n`); + context.log(`Left test directory in '${integTestDir}' ($INTEG_NO_CLEAN)`); } else { await fixture.dispose(success); } @@ -199,40 +135,6 @@ export function withDefaultFixture(block: (context: TestFixture) => Promise; - - /** - * Don't fail when exiting with an error - * - * @default false - */ - allowErrExit?: boolean; - - /** - * Whether to capture stderr - * - * @default true - */ - captureStderr?: boolean; - - /** - * Pass output here - */ - output?: NodeJS.WritableStream; - - /** - * Only return stderr. For example, this is used to validate - * that when CI=true, all logs are sent to stdout. - * - * @default false - */ - onlyStderr?: boolean; -} - export interface CdkCliOptions extends ShellOptions { options?: string[]; neverRequireApproval?: boolean; @@ -315,29 +217,27 @@ export interface CdkModernBootstrapCommandOptions extends CommonCdkBootstrapComm readonly customPermissionsBoundary?: string; } -export class TestFixture { - public readonly qualifier = randomString().slice(0, 10); +export class TestFixture extends ShellHelper { + public readonly qualifier = this.randomString.slice(0, 10); private readonly bucketsToDelete = new Array(); + public readonly packages: IPackageSource; constructor( public readonly integTestDir: string, public readonly stackNamePrefix: string, public readonly output: NodeJS.WritableStream, - public readonly aws: AwsClients) { + public readonly aws: AwsClients, + public readonly randomString: string) { + + super(integTestDir, output); + + this.packages = packageSourceInSubprocess(); } public log(s: string) { this.output.write(`${s}\n`); } - public async shell(command: string[], options: Omit = {}): Promise { - return shell(command, { - output: this.output, - cwd: this.integTestDir, - ...options, - }); - } - public async cdkDeploy(stackNames: string | string[], options: CdkCliOptions = {}) { stackNames = typeof stackNames === 'string' ? [stackNames] : stackNames; @@ -445,13 +345,15 @@ export class TestFixture { public async cdk(args: string[], options: CdkCliOptions = {}) { const verbose = options.verbose ?? true; + await this.packages.makeCliAvailable(); + return this.shell(['cdk', ...(verbose ? ['-v'] : []), ...args], { ...options, modEnv: { AWS_REGION: this.aws.region, AWS_DEFAULT_REGION: this.aws.region, STACK_NAME_PREFIX: this.stackNamePrefix, - PACKAGE_LAYOUT_VERSION: MAJOR_VERSION, + PACKAGE_LAYOUT_VERSION: this.packages.majorVersion(), ...options.modEnv, }, }); @@ -559,33 +461,6 @@ export class TestFixture { } } -/** - * Perform a one-time quick sanity check that the AWS clients has properly configured credentials - * - * If we don't do this, calls are going to fail and they'll be retried and everything will take - * forever before the user notices a simple misconfiguration. - * - * We can't check for the presence of environment variables since credentials could come from - * anywhere, so do simple account retrieval. - * - * Only do it once per process. - */ -async function sanityCheck(aws: AwsClients) { - if (sanityChecked === undefined) { - try { - await aws.account(); - sanityChecked = true; - } catch (e) { - sanityChecked = false; - throw new Error(`AWS credentials probably not configured, got error: ${e.message}`); - } - } - if (!sanityChecked) { - throw new Error('AWS credentials probably not configured, see previous error'); - } -} -let sanityChecked: boolean | undefined; - /** * Make sure that the given environment is bootstrapped * @@ -611,89 +486,10 @@ async function ensureBootstrapped(fixture: TestFixture) { ALREADY_BOOTSTRAPPED_IN_THIS_RUN.add(envSpecifier); } -/** - * A shell command that does what you want - * - * Is platform-aware, handles errors nicely. - */ -export async function shell(command: string[], options: ShellOptions = {}): Promise { - if (options.modEnv && options.env) { - throw new Error('Use either env or modEnv but not both'); - } - - options.output?.write(`💻 ${command.join(' ')}\n`); - - const env = options.env ?? (options.modEnv ? { ...process.env, ...options.modEnv } : undefined); - - const child = child_process.spawn(command[0], command.slice(1), { - ...options, - env, - // Need this for Windows where we want .cmd and .bat to be found as well. - shell: true, - stdio: ['ignore', 'pipe', 'pipe'], - }); - - return new Promise((resolve, reject) => { - const stdout = new Array(); - const stderr = new Array(); - - child.stdout!.on('data', chunk => { - options.output?.write(chunk); - stdout.push(chunk); - }); - - child.stderr!.on('data', chunk => { - options.output?.write(chunk); - if (options.captureStderr ?? true) { - stderr.push(chunk); - } - }); - - child.once('error', reject); - - child.once('close', code => { - const stderrOutput = Buffer.concat(stderr).toString('utf-8'); - const stdoutOutput = Buffer.concat(stdout).toString('utf-8'); - const output = (options.onlyStderr ? stderrOutput : stdoutOutput + stderrOutput).trim(); - if (code === 0 || options.allowErrExit) { - resolve(output); - } else { - reject(new Error(`'${command.join(' ')}' exited with error code ${code}. Output: \n${output}`)); - } - }); - }); -} - function defined(x: A): x is NonNullable { return x !== undefined; } -/** - * rm -rf reimplementation, don't want to depend on an NPM package for this - */ -export function rimraf(fsPath: string) { - try { - const isDir = fs.lstatSync(fsPath).isDirectory(); - - if (isDir) { - for (const file of fs.readdirSync(fsPath)) { - rimraf(path.join(fsPath, file)); - } - fs.rmdirSync(fsPath); - } else { - fs.unlinkSync(fsPath); - } - } catch (e) { - // We will survive ENOENT - if (e.code !== 'ENOENT') { throw e; } - } -} - -export function randomString() { - // Crazy - return Math.random().toString(36).replace(/[^a-z0-9]+/g, ''); -} - /** * Install the given NPM packages, identified by their names and versions * @@ -713,17 +509,6 @@ export function randomString() { * for Node's dependency lookup mechanism). */ export async function installNpmPackages(fixture: TestFixture, packages: Record) { - if (process.env.REPO_ROOT) { - const monoRepo = await findYarnPackages(process.env.REPO_ROOT); - - // Replace the install target with the physical location of this package - for (const key of Object.keys(packages)) { - if (key in monoRepo) { - packages[key] = monoRepo[key]; - } - } - } - fs.writeFileSync(path.join(fixture.integTestDir, 'package.json'), JSON.stringify({ name: 'cdk-integ-tests', private: true, @@ -732,25 +517,7 @@ export async function installNpmPackages(fixture: TestFixture, packages: Record< }, undefined, 2), { encoding: 'utf-8' }); // Now install that `package.json` using NPM7 - const npm7 = await installNpm7(); - await fixture.shell([npm7, 'install']); + await fixture.shell(['node', require.resolve('npm'), 'install']); } -/** - * Install NPM7 somewhere on the machine and return the path to its binary. - * - * - We install NPM7 explicitly so we don't have to depend on the environment. - * - The install is cached so we don't have to install it over and over again - * for every test. - */ -const installNpm7 = memoize0(async (): Promise => { - const installDir = path.join(os.tmpdir(), 'cdk-integ-npm7'); - await shell(['rm', '-rf', installDir]); - await shell(['mkdir', '-p', installDir]); - - await shell(['npm', 'install', 'npm@7'], { cwd: installDir }); - - return path.join(installDir, 'node_modules', '.bin', 'npm'); -}); - const ALREADY_BOOTSTRAPPED_IN_THIS_RUN = new Set(); diff --git a/packages/@aws-cdk-testing/cli-integ/lib/with-packages.ts b/packages/@aws-cdk-testing/cli-integ/lib/with-packages.ts new file mode 100644 index 0000000000000..f835fee3b333a --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/with-packages.ts @@ -0,0 +1,15 @@ +import { IPackageSource } from './package-sources/source'; +import { packageSourceInSubprocess } from './package-sources/subprocess'; + +export interface PackageContext { + readonly packages: IPackageSource; +} + +export function withPackages(block: (context: A & PackageContext) => Promise) { + return async (context: A) => { + return block({ + ...context, + packages: packageSourceInSubprocess(), + }); + }; +} \ No newline at end of file diff --git a/packages/aws-cdk/test/integ/helpers/sam.ts b/packages/@aws-cdk-testing/cli-integ/lib/with-sam.ts similarity index 88% rename from packages/aws-cdk/test/integ/helpers/sam.ts rename to packages/@aws-cdk-testing/cli-integ/lib/with-sam.ts index 13683f88caf2e..1016e4b113923 100644 --- a/packages/aws-cdk/test/integ/helpers/sam.ts +++ b/packages/@aws-cdk-testing/cli-integ/lib/with-sam.ts @@ -3,15 +3,11 @@ import * as fs from 'fs'; import * as os from 'os'; import * as path from 'path'; import axios from 'axios'; -import { AwsClients } from './aws'; -import { - AwsContext, - cloneDirectory, FRAMEWORK_VERSION, installNpmPackages, - MAJOR_VERSION, - randomString, rimraf, ShellOptions, - TestFixture, withAws, -} from './cdk'; -import { TestContext } from './test-helpers'; +import { TestContext } from './integ-test'; +import { RESOURCES_DIR } from './resources'; +import { ShellOptions, rimraf } from './shell'; +import { AwsContext, withAws } from './with-aws'; +import { cloneDirectory, installNpmPackages, TestFixture } from './with-cdk-app'; export interface ActionOutput { @@ -20,32 +16,32 @@ export interface ActionOutput { shellOutput?: string; } - /** * Higher order function to execute a block with a SAM Integration CDK app fixture */ export function withSamIntegrationCdkApp(block: (context: SamIntegrationTestFixture) => Promise) { return async (context: A) => { - const randy = randomString(); + const randy = context.randomString; const stackNamePrefix = `cdktest-${randy}`; const integTestDir = path.join(os.tmpdir(), `cdk-integ-${randy}`); - context.output.write(` Stack prefix: ${stackNamePrefix}\n`); - context.output.write(` Test directory: ${integTestDir}\n`); - context.output.write(` Region: ${context.aws.region}\n`); + context.log(` Stack prefix: ${stackNamePrefix}\n`); + context.log(` Test directory: ${integTestDir}\n`); + context.log(` Region: ${context.aws.region}\n`); - await cloneDirectory(path.join(__dirname, '..', 'cli', 'sam_cdk_integ_app'), integTestDir, context.output); + await cloneDirectory(path.join(RESOURCES_DIR, 'cdk-apps', 'sam_cdk_integ_app'), integTestDir, context.output); const fixture = new SamIntegrationTestFixture( integTestDir, stackNamePrefix, context.output, - context.aws); + context.aws, + context.randomString); let success = true; try { - const installationVersion = FRAMEWORK_VERSION; + const installationVersion = fixture.packages.requestedFrameworkVersion(); - if (MAJOR_VERSION === '1') { + if (fixture.packages.majorVersion() === '1') { await installNpmPackages(fixture, { '@aws-cdk/aws-iam': installationVersion, '@aws-cdk/aws-apigateway': installationVersion, @@ -58,7 +54,7 @@ export function withSamIntegrationCdkApp(blo 'constructs': '^3', }); } else { - const alphaInstallationVersion = installationVersion.includes('rc') ? installationVersion.replace('rc', 'alpha') : `${installationVersion}-alpha.0`; + const alphaInstallationVersion = fixture.packages.requestedAlphaVersion(); await installNpmPackages(fixture, { 'aws-cdk-lib': installationVersion, '@aws-cdk/aws-lambda-go-alpha': alphaInstallationVersion, @@ -76,7 +72,7 @@ export function withSamIntegrationCdkApp(blo throw e; } finally { if (process.env.INTEG_NO_CLEAN) { - process.stderr.write(`Left test directory in '${integTestDir}' ($INTEG_NO_CLEAN)\n`); + context.log(`Left test directory in '${integTestDir}' ($INTEG_NO_CLEAN)\n`); } else { await fixture.dispose(success); } @@ -121,14 +117,6 @@ export function withSamIntegrationFixture(block: (context: SamIntegrationTestFix } export class SamIntegrationTestFixture extends TestFixture { - constructor( - public readonly integTestDir: string, - public readonly stackNamePrefix: string, - public readonly output: NodeJS.WritableStream, - public readonly aws: AwsClients) { - super(integTestDir, stackNamePrefix, output, aws); - } - public async samShell(command: string[], filter?: string, action?: () => any, options: Omit = {}): Promise { return shellWithAction(command, filter, action, { output: this.output, diff --git a/packages/@aws-cdk-testing/cli-integ/lib/with-temporary-directory.ts b/packages/@aws-cdk-testing/cli-integ/lib/with-temporary-directory.ts new file mode 100644 index 0000000000000..0ff0336940114 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/with-temporary-directory.ts @@ -0,0 +1,35 @@ +import * as fs from 'fs'; +import * as os from 'os'; +import * as path from 'path'; +import { TestContext } from './integ-test'; +import { rimraf } from './shell'; + +export interface TemporaryDirectoryContext { + readonly integTestDir: string; +} + +export function withTemporaryDirectory(block: (context: A & TemporaryDirectoryContext) => Promise) { + return async (context: A) => { + const integTestDir = path.join(os.tmpdir(), `cdk-integ-${context.randomString}`); + + fs.mkdirSync(integTestDir, { recursive: true }); + + try { + await block({ + ...context, + integTestDir, + }); + + // Clean up in case of success + if (process.env.SKIP_CLEANUP) { + context.log(`Left test directory in '${integTestDir}' ($SKIP_CLEANUP)\n`); + } else { + rimraf(integTestDir); + } + } catch (e) { + context.log(`Left test directory in '${integTestDir}'\n`); + throw e; + } + }; +} + diff --git a/packages/@aws-cdk-testing/cli-integ/lib/xpmutex.ts b/packages/@aws-cdk-testing/cli-integ/lib/xpmutex.ts new file mode 100644 index 0000000000000..4687164a1b5ee --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/lib/xpmutex.ts @@ -0,0 +1,218 @@ +import { watch, promises as fs, mkdirSync } from 'fs'; +import * as os from 'os'; +import * as path from 'path'; + +export class XpMutexPool { + public static fromDirectory(directory: string) { + mkdirSync(directory, { recursive: true }); + return new XpMutexPool(directory); + } + + public static fromName(name: string) { + return XpMutexPool.fromDirectory(path.join(os.tmpdir(), name)); + } + + private readonly waitingResolvers = new Set<() => void>(); + private watcher: ReturnType | undefined; + + private constructor(public readonly directory: string) { + this.startWatch(); + } + + public mutex(name: string) { + return new XpMutex(this, name); + } + + /** + * Await an unlock event + * + * (An unlock event is when a file in the directory gets deleted, with a tiny + * random sleep attached to it). + */ + public awaitUnlock(maxWaitMs?: number): Promise { + const wait = new Promise(ok => { + this.waitingResolvers.add(async () => { + await randomSleep(10); + ok(); + }); + }); + + if (maxWaitMs) { + return Promise.race([wait, sleep(maxWaitMs)]); + } else { + return wait; + } + } + + private startWatch() { + this.watcher = watch(this.directory); + (this.watcher as any).unref(); // @types doesn't know about this but it exists + this.watcher.on('change', async (eventType, fname) => { + // Only trigger on 'deletes'. + // After receiving the event, we check if the file exists. + // - If no: the file was deleted! Huzzah, this counts as a wakeup. + // - If yes: either the file was just created (in which case we don't need to wakeup) + // or the event was due to a delete but someone raced us to it and claimed the + // file already (in which case we also don't need to wake up). + if (eventType === 'rename' && !await fileExists(path.join(this.directory, fname.toString()))) { + this.notifyWaiters(); + } + }); + this.watcher.on('error', async (e) => { + // eslint-disable-next-line no-console + console.error(e); + await randomSleep(100); + this.startWatch(); + }); + } + + private notifyWaiters() { + for (const promise of this.waitingResolvers) { + promise(); + } + this.waitingResolvers.clear(); + } +} + +/** + * Cross-process mutex + * + * Uses the presence of a file on disk and `fs.watch` to represent the mutex + * and discover unlocks. + */ +export class XpMutex { + private readonly fileName: string; + + constructor(private readonly pool: XpMutexPool, public readonly mutexName: string) { + this.fileName = path.join(pool.directory, `${mutexName}.mutex`); + } + + /** + * Try to acquire the lock (may fail) + */ + public async tryAcquire(): Promise { + while (true) { + // Acquire lock by being the one to create the file + try { + return await this.writePidFile('wx'); // Fails if the file already exists + } catch (e) { + if (e.code !== 'EEXIST') { throw e; } + } + + // File already exists. Read the contents, see if it's an existent PID (if so, the lock is taken) + const ownerPid = await this.readPidFile(); + if (ownerPid === undefined) { + // File got deleted just now, maybe we can acquire it again + continue; + } + if (processExists(ownerPid)) { + return undefined; + } + + // If not, the lock is stale and will never be released anymore. We may + // delete it and acquire it anyway, but we may be racing someone else trying + // to do the same. Solve this as follows: + // - Try to acquire a lock that gives us permissions to declare the existing lock stale. + // - Sleep a small random period to reduce contention on this operation + await randomSleep(10); + const innerMux = new XpMutex(this.pool, `${this.mutexName}.${ownerPid}`); + const innerLock = await innerMux.tryAcquire(); + if (!innerLock) { + return undefined; + } + + // We may not release the 'inner lock' we used to acquire the rights to declare the other + // lock stale until we release the actual lock itself. If we did, other contenders might + // see it released while they're still in this fallback block and accidentally steal + // from a new legitimate owner. + return this.writePidFile('w', innerLock); // Force write lock file, attach inner lock as well + } + } + + /** + * Acquire the lock, waiting until we can + */ + public async acquire(): Promise { + while (true) { + // Start the wait here, so we don't miss the signal if it comes after + // we try but before we sleep. + // + // We also periodically retry anyway since we may have missed the delete + // signal due to unfortunate timing. + const wait = this.pool.awaitUnlock(5000); + + const lock = await this.acquire(); + if (lock) { + // Ignore the wait (count as handled) + wait.then(() => {}, () => {}); + return lock; + } + + await wait; + await randomSleep(100); + } + } + + private async readPidFile(): Promise { + const deadLine = Date.now() + 1000; + while (Date.now() < deadLine) { + let contents; + try { + contents = await fs.readFile(this.fileName, { encoding: 'utf-8' }); + } catch (e) { + if (e.code === 'ENOENT') { return undefined; } + throw e; + } + + // Retry until we've seen the full contents + if (contents.endsWith('.')) { return parseInt(contents.substring(0, contents.length - 1), 10); } + await sleep(10); + } + + throw new Error(`${this.fileName} was never completely written`); + } + + private async writePidFile(mode: string, additionalLock?: ILock): Promise { + const fd = await fs.open(this.fileName, mode); // May fail if the file already exists + await fd.write(`${process.pid}.`); // Period guards against partial reads + await fd.close(); + + return { + release: async () => { + await fs.unlink(this.fileName); + await additionalLock?.release(); + }, + }; + } +} + +export interface ILock { + release(): Promise; +} + +async function fileExists(fileName: string) { + try { + await fs.stat(fileName); + return true; + } catch (e) { + if (e.code === 'ENOENT') { return false; } + throw e; + } +} + +function processExists(pid: number) { + try { + process.kill(pid, 0); + return true; + } catch (e) { + return false; + } +} + +function sleep(ms: number): Promise { + return new Promise(ok => (setTimeout(ok, ms) as any).unref()); +} + +function randomSleep(ms: number) { + return sleep(Math.floor(Math.random() * ms)); +} diff --git a/packages/@aws-cdk-testing/cli-integ/package.json b/packages/@aws-cdk-testing/cli-integ/package.json new file mode 100644 index 0000000000000..87664899ef841 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/package.json @@ -0,0 +1,73 @@ +{ + "name": "@aws-cdk-testing/cli-integ", + "description": "Integration tests for the AWS CDK CLI", + "version": "0.0.0", + "bin": { + "run-suite": "bin/run-suite", + "download-and-run-old-tests": "bin/download-and-run-old-tests", + "query-github": "bin/query-github", + "apply-patches": "bin/apply-patches", + "test-root": "bin/test-root", + "stage-distribution": "bin/stage-distribution" + }, + "scripts": { + "build": "cdk-build", + "watch": "cdk-watch", + "lint": "cdk-lint", + "pkglint": "pkglint -f", + "test": "cdk-test", + "package": "cdk-package", + "build+test": "yarn build && yarn test", + "build+extract": "yarn build", + "build+test+package": "yarn build+test && yarn package", + "build+test+extract": "yarn build+test" + }, + "author": { + "name": "Amazon Web Services", + "url": "https://aws.amazon.com", + "organization": true + }, + "license": "Apache-2.0", + "devDependencies": { + "@types/node": "^14.18.31", + "@aws-cdk/cdk-build-tools": "0.0.0", + "@types/semver": "^7.3.12", + "@types/yargs": "^17.0.13", + "@types/fs-extra": "^9.0.0", + "@types/glob": "^7.2.0", + "@types/npm": "^7.19.0", + "@aws-cdk/pkglint": "0.0.0" + }, + "dependencies": { + "@octokit/rest": "^18.12.0", + "jest": "^27.5.1", + "aws-sdk": "^2.1211.0", + "axios": "^0.27.2", + "jest-junit": "^14.0.0", + "semver": "^7.3.8", + "ts-mock-imports": "^1.3.8", + "yargs": "^17.5.0", + "glob": "^7.2.3", + "p-queue": "^6.6.2", + "fs-extra": "^9.1.0", + "npm": "^8.11.0" + }, + "repository": { + "url": "https://github.com/aws/aws-cdk.git", + "type": "git", + "directory": "packages/@aws-cdk-testing/cli-integ" + }, + "keywords": [ + "aws", + "cdk" + ], + "homepage": "https://github.com/aws/aws-cdk", + "engines": { + "node": ">= 14.15.0" + }, + "stability": "experimental", + "maturity": "experimental", + "publishConfig": { + "tag": "latest" + } +} diff --git a/packages/aws-cdk/test/integ/cli/app/app.js b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/app/app.js similarity index 100% rename from packages/aws-cdk/test/integ/cli/app/app.js rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/app/app.js diff --git a/packages/aws-cdk/test/integ/cli/app/cdk.json b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/app/cdk.json similarity index 100% rename from packages/aws-cdk/test/integ/cli/app/cdk.json rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/app/cdk.json diff --git a/packages/aws-cdk/test/integ/cli/app/docker/Dockerfile b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/app/docker/Dockerfile similarity index 100% rename from packages/aws-cdk/test/integ/cli/app/docker/Dockerfile rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/app/docker/Dockerfile diff --git a/packages/aws-cdk/test/integ/cli/app/docker/Dockerfile.Custom b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/app/docker/Dockerfile.Custom similarity index 100% rename from packages/aws-cdk/test/integ/cli/app/docker/Dockerfile.Custom rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/app/docker/Dockerfile.Custom diff --git a/packages/aws-cdk/test/integ/cli/app/lambda/index.js b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/app/lambda/index.js similarity index 100% rename from packages/aws-cdk/test/integ/cli/app/lambda/index.js rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/app/lambda/index.js diff --git a/packages/aws-cdk/test/integ/cli/app/lambda/response.json b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/app/lambda/response.json similarity index 100% rename from packages/aws-cdk/test/integ/cli/app/lambda/response.json rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/app/lambda/response.json diff --git a/packages/aws-cdk/test/integ/cli/app/nested-stack.js b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/app/nested-stack.js similarity index 100% rename from packages/aws-cdk/test/integ/cli/app/nested-stack.js rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/app/nested-stack.js diff --git a/packages/aws-cdk/test/integ/uberpackage/cfn-include-app/.gitignore b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/cfn-include-app/.gitignore similarity index 100% rename from packages/aws-cdk/test/integ/uberpackage/cfn-include-app/.gitignore rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/cfn-include-app/.gitignore diff --git a/packages/aws-cdk/test/integ/uberpackage/cfn-include-app/cdk.json b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/cfn-include-app/cdk.json similarity index 100% rename from packages/aws-cdk/test/integ/uberpackage/cfn-include-app/cdk.json rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/cfn-include-app/cdk.json diff --git a/packages/aws-cdk/test/integ/uberpackage/cfn-include-app/cfn-include-app.js b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/cfn-include-app/cfn-include-app.js similarity index 100% rename from packages/aws-cdk/test/integ/uberpackage/cfn-include-app/cfn-include-app.js rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/cfn-include-app/cfn-include-app.js diff --git a/packages/aws-cdk/test/integ/uberpackage/cfn-include-app/example-template.json b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/cfn-include-app/example-template.json similarity index 100% rename from packages/aws-cdk/test/integ/uberpackage/cfn-include-app/example-template.json rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/cfn-include-app/example-template.json diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/bin/test-app.js b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/bin/test-app.js similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/bin/test-app.js rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/bin/test-app.js diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/cdk.json b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/cdk.json similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/cdk.json rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/cdk.json diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/lib/nested-stack.js b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/lib/nested-stack.js similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/lib/nested-stack.js rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/lib/nested-stack.js diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/lib/test-stack.js b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/lib/test-stack.js similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/lib/test-stack.js rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/lib/test-stack.js diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/.no-packagejson-validator b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/.no-packagejson-validator similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/.no-packagejson-validator rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/.no-packagejson-validator diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/Dockerfile b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/Dockerfile similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/Dockerfile rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/Dockerfile diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/app.js b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/app.js similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/app.js rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/app.js diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/package.json b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/package.json similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/package.json rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/package.json diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/go/GoFunctionConstruct/go.mod b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/go/GoFunctionConstruct/go.mod similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/go/GoFunctionConstruct/go.mod rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/go/GoFunctionConstruct/go.mod diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/go/GoFunctionConstruct/go.sum b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/go/GoFunctionConstruct/go.sum similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/go/GoFunctionConstruct/go.sum rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/go/GoFunctionConstruct/go.sum diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/go/GoFunctionConstruct/main.go b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/go/GoFunctionConstruct/main.go similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/go/GoFunctionConstruct/main.go rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/go/GoFunctionConstruct/main.go diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/.no-packagejson-validator b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/.no-packagejson-validator similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/.no-packagejson-validator rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/.no-packagejson-validator diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/app.ts b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/app.ts similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/app.ts rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/app.ts diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/package-lock.json b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/package-lock.json similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/package-lock.json rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/package-lock.json diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/package.json b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/package.json similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/package.json rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/package.json diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/python/Function/app.py b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/python/Function/app.py similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/python/Function/app.py rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/python/Function/app.py diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/python/Function/requirements.txt b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/python/Function/requirements.txt similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/python/Function/requirements.txt rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/python/Function/requirements.txt diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/python/Layer/layer_version_dependency.py b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/python/Layer/layer_version_dependency.py similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/python/Layer/layer_version_dependency.py rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/python/Layer/layer_version_dependency.py diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/python/Layer/requirements.txt b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/python/Layer/requirements.txt similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/python/Layer/requirements.txt rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/python/Layer/requirements.txt diff --git a/packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/rest-api-definition.yaml b/packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/rest-api-definition.yaml similarity index 100% rename from packages/aws-cdk/test/integ/cli/sam_cdk_integ_app/src/rest-api-definition.yaml rename to packages/@aws-cdk-testing/cli-integ/resources/cdk-apps/sam_cdk_integ_app/src/rest-api-definition.yaml diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.119.0/NOTES.md b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.119.0/NOTES.md similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.119.0/NOTES.md rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.119.0/NOTES.md diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.119.0/cli.integtest.js b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.119.0/cli.integtest.js similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.119.0/cli.integtest.js rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.119.0/cli.integtest.js diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.130.0/NOTES.md b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.130.0/NOTES.md similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.130.0/NOTES.md rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.130.0/NOTES.md diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.130.0/app/app.js b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.130.0/app/app.js similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.130.0/app/app.js rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.130.0/app/app.js diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.130.0/bootstrapping.integtest.js b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.130.0/bootstrapping.integtest.js similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.130.0/bootstrapping.integtest.js rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.130.0/bootstrapping.integtest.js diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.44.0/NOTES.md b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.44.0/NOTES.md similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.44.0/NOTES.md rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.44.0/NOTES.md diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.44.0/bootstrapping.integtest.js b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.44.0/bootstrapping.integtest.js similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.44.0/bootstrapping.integtest.js rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.44.0/bootstrapping.integtest.js diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.44.0/test.sh b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.44.0/test.sh similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.44.0/test.sh rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.44.0/test.sh diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.61.1/NOTES.md b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.61.1/NOTES.md similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.61.1/NOTES.md rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.61.1/NOTES.md diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.61.1/skip-tests.txt b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.61.1/skip-tests.txt similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.61.1/skip-tests.txt rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.61.1/skip-tests.txt diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.62.0/NOTES.md b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.62.0/NOTES.md similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.62.0/NOTES.md rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.62.0/NOTES.md diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.62.0/aws-helpers.js b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.62.0/aws-helpers.js similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.62.0/aws-helpers.js rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.62.0/aws-helpers.js diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.63.0/NOTES.md b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.63.0/NOTES.md similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.63.0/NOTES.md rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.63.0/NOTES.md diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.63.0/skip-tests.txt b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.63.0/skip-tests.txt similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.63.0/skip-tests.txt rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.63.0/skip-tests.txt diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.64.0/NOTES.md b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.64.0/NOTES.md similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.64.0/NOTES.md rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.64.0/NOTES.md diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.64.0/cdk-helpers.js b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.64.0/cdk-helpers.js similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.64.0/cdk-helpers.js rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.64.0/cdk-helpers.js diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.64.0/cli.integtest.js b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.64.0/cli.integtest.js similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.64.0/cli.integtest.js rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.64.0/cli.integtest.js diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.64.1/NOTES.md b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.64.1/NOTES.md similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.64.1/NOTES.md rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.64.1/NOTES.md diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.64.1/cdk-helpers.js b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.64.1/cdk-helpers.js similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.64.1/cdk-helpers.js rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.64.1/cdk-helpers.js diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.64.1/cli.integtest.js b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.64.1/cli.integtest.js similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.64.1/cli.integtest.js rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.64.1/cli.integtest.js diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.67.0/NOTES.md b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.67.0/NOTES.md similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.67.0/NOTES.md rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.67.0/NOTES.md diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/v1.67.0/cdk-helpers.js b/packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.67.0/cdk-helpers.js similarity index 100% rename from packages/aws-cdk/test/integ/cli-regression-patches/v1.67.0/cdk-helpers.js rename to packages/@aws-cdk-testing/cli-integ/resources/cli-regression-patches/v1.67.0/cdk-helpers.js diff --git a/packages/aws-cdk/test/integ/cli/cloud-assemblies/0.36.0/InitStack.template.json b/packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/0.36.0/InitStack.template.json similarity index 100% rename from packages/aws-cdk/test/integ/cli/cloud-assemblies/0.36.0/InitStack.template.json rename to packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/0.36.0/InitStack.template.json diff --git a/packages/aws-cdk/test/integ/cli/cloud-assemblies/0.36.0/cdk.out b/packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/0.36.0/cdk.out similarity index 100% rename from packages/aws-cdk/test/integ/cli/cloud-assemblies/0.36.0/cdk.out rename to packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/0.36.0/cdk.out diff --git a/packages/aws-cdk/test/integ/cli/cloud-assemblies/0.36.0/manifest.json b/packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/0.36.0/manifest.json similarity index 100% rename from packages/aws-cdk/test/integ/cli/cloud-assemblies/0.36.0/manifest.json rename to packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/0.36.0/manifest.json diff --git a/packages/aws-cdk/test/integ/cli/cloud-assemblies/1.10.0-lookup-default-vpc/InitStack.template.json b/packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/1.10.0-lookup-default-vpc/InitStack.template.json similarity index 100% rename from packages/aws-cdk/test/integ/cli/cloud-assemblies/1.10.0-lookup-default-vpc/InitStack.template.json rename to packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/1.10.0-lookup-default-vpc/InitStack.template.json diff --git a/packages/aws-cdk/test/integ/cli/cloud-assemblies/1.10.0-lookup-default-vpc/cdk.out b/packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/1.10.0-lookup-default-vpc/cdk.out similarity index 100% rename from packages/aws-cdk/test/integ/cli/cloud-assemblies/1.10.0-lookup-default-vpc/cdk.out rename to packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/1.10.0-lookup-default-vpc/cdk.out diff --git a/packages/aws-cdk/test/integ/cli/cloud-assemblies/1.10.0-lookup-default-vpc/manifest.json.js b/packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/1.10.0-lookup-default-vpc/manifest.json.js similarity index 100% rename from packages/aws-cdk/test/integ/cli/cloud-assemblies/1.10.0-lookup-default-vpc/manifest.json.js rename to packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/1.10.0-lookup-default-vpc/manifest.json.js diff --git a/packages/aws-cdk/test/integ/cli/cloud-assemblies/1.10.0-request-azs/InitStack.template.json b/packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/1.10.0-request-azs/InitStack.template.json similarity index 100% rename from packages/aws-cdk/test/integ/cli/cloud-assemblies/1.10.0-request-azs/InitStack.template.json rename to packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/1.10.0-request-azs/InitStack.template.json diff --git a/packages/aws-cdk/test/integ/cli/cloud-assemblies/1.10.0-request-azs/cdk.out b/packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/1.10.0-request-azs/cdk.out similarity index 100% rename from packages/aws-cdk/test/integ/cli/cloud-assemblies/1.10.0-request-azs/cdk.out rename to packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/1.10.0-request-azs/cdk.out diff --git a/packages/aws-cdk/test/integ/cli/cloud-assemblies/1.10.0-request-azs/manifest.json.js b/packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/1.10.0-request-azs/manifest.json.js similarity index 100% rename from packages/aws-cdk/test/integ/cli/cloud-assemblies/1.10.0-request-azs/manifest.json.js rename to packages/@aws-cdk-testing/cli-integ/resources/cloud-assemblies/1.10.0-request-azs/manifest.json.js diff --git a/packages/@aws-cdk-testing/cli-integ/resources/integ.jest.config.js b/packages/@aws-cdk-testing/cli-integ/resources/integ.jest.config.js new file mode 100644 index 0000000000000..e72d95ff70da6 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/resources/integ.jest.config.js @@ -0,0 +1,25 @@ +const path = require('path'); + +const rootDir = path.resolve(__dirname, '..', 'tests', process.env.TEST_SUITE_NAME); + +if (rootDir.includes('node_modules')) { + // Jest < 28 under no circumstances supports loading test if there's node_modules anywhere in the path, + // and Jest >= 28 requires a newer TypeScript version than the one we support. + throw new Error(`This package must not be 'npm install'ed (found node_modules in dir: ${rootDir})`); +} + +module.exports = { + rootDir, + testMatch: [`**/*.integtest.js`], + moduleFileExtensions: ["js"], + + testEnvironment: "node", + testTimeout: 300000, + + // Affects test.concurrent(), these are self-limiting anyway + maxConcurrency: 10, + reporters: [ + "default", + [ "jest-junit", { suiteName: "jest tests", outputDirectory: "coverage" } ] + ] +}; diff --git a/packages/aws-cdk/test/integ/helpers/skip-tests.txt b/packages/@aws-cdk-testing/cli-integ/skip-tests.txt similarity index 100% rename from packages/aws-cdk/test/integ/helpers/skip-tests.txt rename to packages/@aws-cdk-testing/cli-integ/skip-tests.txt diff --git a/packages/@aws-cdk-testing/cli-integ/test/resource-pool.test.ts b/packages/@aws-cdk-testing/cli-integ/test/resource-pool.test.ts new file mode 100644 index 0000000000000..18f153778bb5f --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/test/resource-pool.test.ts @@ -0,0 +1,84 @@ +import { sleep } from '../lib'; +import { ResourcePool } from '../lib/resource-pool'; + +const POOL_NAME = 'resource-pool.test'; + +test('take and dispose', async () => { + const pool = ResourcePool.withResources(POOL_NAME, ['a']); + const take1 = pool.take(); + const take2 = pool.take(); + + let released = false; + + const lease1 = await take1; + // awaiting 'take2' would now block but we add an async + // handler to it to flip a boolean to see when it gets activated. + void(take2.then(() => released = true)); + + expect(lease1.value).toEqual('a'); + await waitTick(); + expect(released).toEqual(false); + + await lease1.dispose(); + await waitTick(); // This works because setImmediate is scheduled in LIFO order + + const lease2 = await take2; + await lease2.dispose(); + expect(released).toEqual(true); +}); + +test('double dispose throws', async () => { + const pool = ResourcePool.withResources(POOL_NAME, ['a']); + const lease = await pool.take(); + + await lease.dispose(); + expect(() => lease.dispose()).toThrow(); +}); + +test('somewhat balance', async () => { + const counters = { + a: 0, + b: 0, + c: 0, + d: 0, + e: 0, + }; + const N = 100; + let maxConcurrency = 0; + let concurrency = 0; + + const keys = Object.keys(counters) as Array ; + const pool = ResourcePool.withResources(POOL_NAME, keys); + await Promise.all(Array.from(range(N)).map(() => + pool.using(async (x) => { + counters[x] += 1; + concurrency += 1; + maxConcurrency = Math.max(maxConcurrency, concurrency); + try { + await sleep(10); + } finally { + concurrency -= 1; + } + }), + )); + + // Regardless of which resource(s) we used, the total count should add up to N + const sum = Object.values(counters).reduce((a, b) => a + b, 0); + expect(sum).toEqual(N); + // There was concurrency + expect(maxConcurrency).toBeGreaterThan(2); + // All counters are used + for (const count of Object.values(counters)) { + expect(count).toBeGreaterThan(0); + } +}); + +function waitTick() { + return new Promise(setImmediate); +} + +function* range(n: number) { + for (let i = 0; i < n; i++) { + yield i; + } +} \ No newline at end of file diff --git a/packages/aws-cdk/test/integ/cli/README.md b/packages/@aws-cdk-testing/cli-integ/tests/cli-integ-tests/README.md similarity index 99% rename from packages/aws-cdk/test/integ/cli/README.md rename to packages/@aws-cdk-testing/cli-integ/tests/cli-integ-tests/README.md index 0a174245e8504..a26666bff695e 100644 --- a/packages/aws-cdk/test/integ/cli/README.md +++ b/packages/@aws-cdk-testing/cli-integ/tests/cli-integ-tests/README.md @@ -17,7 +17,6 @@ Running against a failing dist build: .../CMkBR4V$ package/test/integ/run-against-dist package/test/integ/cli/test.sh ``` - ## Adding tests Even though tests are now written in TypeScript, this does not diff --git a/packages/aws-cdk/test/integ/cli/bootstrapping.integtest.ts b/packages/@aws-cdk-testing/cli-integ/tests/cli-integ-tests/bootstrapping.integtest.ts similarity index 98% rename from packages/aws-cdk/test/integ/cli/bootstrapping.integtest.ts rename to packages/@aws-cdk-testing/cli-integ/tests/cli-integ-tests/bootstrapping.integtest.ts index 037b241f3bc92..4f0c2503b94f8 100644 --- a/packages/aws-cdk/test/integ/cli/bootstrapping.integtest.ts +++ b/packages/@aws-cdk-testing/cli-integ/tests/cli-integ-tests/bootstrapping.integtest.ts @@ -1,12 +1,11 @@ import * as fs from 'fs'; import * as path from 'path'; -import { randomString, withDefaultFixture } from '../helpers/cdk'; -import { integTest } from '../helpers/test-helpers'; +import { integTest, randomString, withDefaultFixture } from '../../lib'; const timeout = process.env.CODEBUILD_BUILD_ID ? // if the process is running in CodeBuild 3_600_000 : // 1 hour 600_000; // 10 minutes -jest.setTimeout(timeout); +jest.setTimeout(timeout); // Includes the time to acquire locks process.stdout.write(`bootstrapping.integtest.ts: Setting jest time out to ${timeout} ms`); integTest('can bootstrap without execution', withDefaultFixture(async (fixture) => { diff --git a/packages/aws-cdk/test/integ/cli/cli.integtest.ts b/packages/@aws-cdk-testing/cli-integ/tests/cli-integ-tests/cli.integtest.ts similarity index 93% rename from packages/aws-cdk/test/integ/cli/cli.integtest.ts rename to packages/@aws-cdk-testing/cli-integ/tests/cli-integ-tests/cli.integtest.ts index bac932e23ea4b..6d868b8f1db33 100644 --- a/packages/aws-cdk/test/integ/cli/cli.integtest.ts +++ b/packages/@aws-cdk-testing/cli-integ/tests/cli-integ-tests/cli.integtest.ts @@ -1,12 +1,9 @@ import { promises as fs, existsSync } from 'fs'; import * as os from 'os'; import * as path from 'path'; -import { retry, sleep } from '../helpers/aws'; -import { cloneDirectory, MAJOR_VERSION, shell, withDefaultFixture } from '../helpers/cdk'; -import { randomInteger, withSamIntegrationFixture } from '../helpers/sam'; -import { integTest } from '../helpers/test-helpers'; +import { integTest, cloneDirectory, shell, withDefaultFixture, retry, sleep, randomInteger, withSamIntegrationFixture, RESOURCES_DIR } from '../../lib'; -jest.setTimeout(600_000); +jest.setTimeout(60 * 60_000); // Includes the time to acquire locks describe('ci', () => { integTest('output to stderr', withDefaultFixture(async (fixture) => { @@ -486,86 +483,88 @@ integTest('deploy with notification ARN', withDefaultFixture(async (fixture) => } })); -if (MAJOR_VERSION === '1') { - // NOTE: this doesn't currently work with modern-style synthesis, as the bootstrap - // role by default will not have permission to iam:PassRole the created role. - integTest('deploy with role', withDefaultFixture(async (fixture) => { - const roleName = `${fixture.stackNamePrefix}-test-role`; - - await deleteRole(); +// NOTE: this doesn't currently work with modern-style synthesis, as the bootstrap +// role by default will not have permission to iam:PassRole the created role. +integTest('deploy with role', withDefaultFixture(async (fixture) => { + if (fixture.packages.majorVersion() !== '1') { + return; // Nothing to do + } - const createResponse = await fixture.aws.iam('createRole', { + const roleName = `${fixture.stackNamePrefix}-test-role`; + + await deleteRole(); + + const createResponse = await fixture.aws.iam('createRole', { + RoleName: roleName, + AssumeRolePolicyDocument: JSON.stringify({ + Version: '2012-10-17', + Statement: [{ + Action: 'sts:AssumeRole', + Principal: { Service: 'cloudformation.amazonaws.com' }, + Effect: 'Allow', + }, { + Action: 'sts:AssumeRole', + Principal: { AWS: (await fixture.aws.sts('getCallerIdentity', {})).Arn }, + Effect: 'Allow', + }], + }), + }); + const roleArn = createResponse.Role.Arn; + try { + await fixture.aws.iam('putRolePolicy', { RoleName: roleName, - AssumeRolePolicyDocument: JSON.stringify({ + PolicyName: 'DefaultPolicy', + PolicyDocument: JSON.stringify({ Version: '2012-10-17', Statement: [{ - Action: 'sts:AssumeRole', - Principal: { Service: 'cloudformation.amazonaws.com' }, - Effect: 'Allow', - }, { - Action: 'sts:AssumeRole', - Principal: { AWS: (await fixture.aws.sts('getCallerIdentity', {})).Arn }, + Action: '*', + Resource: '*', Effect: 'Allow', }], }), }); - const roleArn = createResponse.Role.Arn; - try { - await fixture.aws.iam('putRolePolicy', { - RoleName: roleName, - PolicyName: 'DefaultPolicy', - PolicyDocument: JSON.stringify({ - Version: '2012-10-17', - Statement: [{ - Action: '*', - Resource: '*', - Effect: 'Allow', - }], - }), - }); - await retry(fixture.output, 'Trying to assume fresh role', retry.forSeconds(300), async () => { - await fixture.aws.sts('assumeRole', { - RoleArn: roleArn, - RoleSessionName: 'testing', - }); + await retry(fixture.output, 'Trying to assume fresh role', retry.forSeconds(300), async () => { + await fixture.aws.sts('assumeRole', { + RoleArn: roleArn, + RoleSessionName: 'testing', }); + }); - // In principle, the role has replicated from 'us-east-1' to wherever we're testing. - // Give it a little more sleep to make sure CloudFormation is not hitting a box - // that doesn't have it yet. - await sleep(5000); + // In principle, the role has replicated from 'us-east-1' to wherever we're testing. + // Give it a little more sleep to make sure CloudFormation is not hitting a box + // that doesn't have it yet. + await sleep(5000); - await fixture.cdkDeploy('test-2', { - options: ['--role-arn', roleArn], - }); + await fixture.cdkDeploy('test-2', { + options: ['--role-arn', roleArn], + }); - // Immediately delete the stack again before we delete the role. - // - // Since roles are sticky, if we delete the role before the stack, subsequent DeleteStack - // operations will fail when CloudFormation tries to assume the role that's already gone. - await fixture.cdkDestroy('test-2'); + // Immediately delete the stack again before we delete the role. + // + // Since roles are sticky, if we delete the role before the stack, subsequent DeleteStack + // operations will fail when CloudFormation tries to assume the role that's already gone. + await fixture.cdkDestroy('test-2'); - } finally { - await deleteRole(); - } + } finally { + await deleteRole(); + } - async function deleteRole() { - try { - for (const policyName of (await fixture.aws.iam('listRolePolicies', { RoleName: roleName })).PolicyNames) { - await fixture.aws.iam('deleteRolePolicy', { - RoleName: roleName, - PolicyName: policyName, - }); - } - await fixture.aws.iam('deleteRole', { RoleName: roleName }); - } catch (e) { - if (e.message.indexOf('cannot be found') > -1) { return; } - throw e; + async function deleteRole() { + try { + for (const policyName of (await fixture.aws.iam('listRolePolicies', { RoleName: roleName })).PolicyNames) { + await fixture.aws.iam('deleteRolePolicy', { + RoleName: roleName, + PolicyName: policyName, + }); } + await fixture.aws.iam('deleteRole', { RoleName: roleName }); + } catch (e) { + if (e.message.indexOf('cannot be found') > -1) { return; } + throw e; } - })); -} + } +})); integTest('cdk diff', withDefaultFixture(async (fixture) => { const diff1 = await fixture.cdk(['diff', fixture.fullStackName('test-1')]); @@ -791,7 +790,7 @@ integTest('failed deploy does not hang', withDefaultFixture(async (fixture) => { integTest('can still load old assemblies', withDefaultFixture(async (fixture) => { const cxAsmDir = path.join(os.tmpdir(), 'cdk-integ-cx'); - const testAssembliesDirectory = path.join(__dirname, 'cloud-assemblies'); + const testAssembliesDirectory = path.join(RESOURCES_DIR, 'cloud-assemblies'); for (const asmdir of await listChildDirs(testAssembliesDirectory)) { fixture.log(`ASSEMBLY ${asmdir}`); await cloneDirectory(asmdir, cxAsmDir); diff --git a/packages/@aws-cdk-testing/cli-integ/tests/init-csharp/init-csharp.integtest.ts b/packages/@aws-cdk-testing/cli-integ/tests/init-csharp/init-csharp.integtest.ts new file mode 100644 index 0000000000000..a36b1d628347e --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/tests/init-csharp/init-csharp.integtest.ts @@ -0,0 +1,16 @@ +import { integTest, withTemporaryDirectory, ShellHelper, withPackages } from '../../lib'; + +['app', 'sample-app'].forEach(template => { + integTest(`init C♯ ${template}`, withTemporaryDirectory(withPackages(async (context) => { + context.packages.assertJsiiPackagesAvailable(); + + const shell = ShellHelper.fromContext(context); + await context.packages.makeCliAvailable(); + + await shell.shell(['cdk', 'init', '-l', 'csharp', template]); + await context.packages.initializeDotnetPackages(context.integTestDir); + await shell.shell(['cdk', 'synth']); + }))); +}); + + diff --git a/packages/@aws-cdk-testing/cli-integ/tests/init-fsharp/init-fsharp.integtest.ts b/packages/@aws-cdk-testing/cli-integ/tests/init-fsharp/init-fsharp.integtest.ts new file mode 100644 index 0000000000000..fdc1fca2d4cd1 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/tests/init-fsharp/init-fsharp.integtest.ts @@ -0,0 +1,15 @@ +import { integTest, withTemporaryDirectory, ShellHelper, withPackages } from '../../lib'; + +['app', 'sample-app'].forEach(template => { + integTest(`init F♯ ${template}`, withTemporaryDirectory(withPackages(async (context) => { + context.packages.assertJsiiPackagesAvailable(); + + const shell = ShellHelper.fromContext(context); + await context.packages.makeCliAvailable(); + + await shell.shell(['cdk', 'init', '-l', 'fsharp', template]); + await context.packages.initializeDotnetPackages(context.integTestDir); + await shell.shell(['cdk', 'synth']); + }))); +}); + diff --git a/packages/@aws-cdk-testing/cli-integ/tests/init-java/init-java.integtest.ts b/packages/@aws-cdk-testing/cli-integ/tests/init-java/init-java.integtest.ts new file mode 100644 index 0000000000000..48d5b38b1e2db --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/tests/init-java/init-java.integtest.ts @@ -0,0 +1,14 @@ +import { integTest, withTemporaryDirectory, ShellHelper, withPackages } from '../../lib'; + +['app', 'sample-app'].forEach(template => { + integTest(`init java ${template}`, withTemporaryDirectory(withPackages(async (context) => { + context.packages.assertJsiiPackagesAvailable(); + + const shell = ShellHelper.fromContext(context); + await context.packages.makeCliAvailable(); + + await shell.shell(['cdk', 'init', '-l', 'java', template]); + await shell.shell(['mvn', 'package']); + await shell.shell(['cdk', 'synth']); + }))); +}); diff --git a/packages/@aws-cdk-testing/cli-integ/tests/init-javascript/init-javascript.integtest.ts b/packages/@aws-cdk-testing/cli-integ/tests/init-javascript/init-javascript.integtest.ts new file mode 100644 index 0000000000000..8fc4be4bf64fb --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/tests/init-javascript/init-javascript.integtest.ts @@ -0,0 +1,15 @@ +import { integTest, withTemporaryDirectory, ShellHelper, withPackages } from '../../lib'; + +['app', 'sample-app'].forEach(template => { + integTest(`init javascript ${template}`, withTemporaryDirectory(withPackages(async (context) => { + const shell = ShellHelper.fromContext(context); + await context.packages.makeCliAvailable(); + + await shell.shell(['cdk', 'init', '-l', 'javascript', template]); + await shell.shell(['npm', 'prune']); + await shell.shell(['npm', 'ls']); // this will fail if we have unmet peer dependencies + await shell.shell(['npm', 'run', 'test']); + + await shell.shell(['cdk', 'synth']); + }))); +}); diff --git a/packages/@aws-cdk-testing/cli-integ/tests/init-python/init-python.integtest.ts b/packages/@aws-cdk-testing/cli-integ/tests/init-python/init-python.integtest.ts new file mode 100644 index 0000000000000..f7839fd9a0e15 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/tests/init-python/init-python.integtest.ts @@ -0,0 +1,20 @@ +import * as path from 'path'; +import { integTest, withTemporaryDirectory, ShellHelper, withPackages } from '../../lib'; + +['app', 'sample-app'].forEach(template => { + integTest(`init python ${template}`, withTemporaryDirectory(withPackages(async (context) => { + context.packages.assertJsiiPackagesAvailable(); + + const shell = ShellHelper.fromContext(context); + await context.packages.makeCliAvailable(); + + await shell.shell(['cdk', 'init', '-l', 'python', template]); + const venvPath = path.resolve(context.integTestDir, '.venv'); + const venv = { PATH: `${venvPath}/bin:${process.env.PATH}`, VIRTUAL_ENV: venvPath }; + + await shell.shell([`${venvPath}/bin/pip`, 'install', '-r', 'requirements.txt'], { modEnv: venv }); + await shell.shell([`${venvPath}/bin/pip`, 'install', '-r', 'requirements-dev.txt'], { modEnv: venv }); + await shell.shell([`${venvPath}/bin/pytest`], { modEnv: venv }); + await shell.shell(['cdk', 'synth'], { modEnv: venv }); + }))); +}); \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/tests/init-typescript-app/init-typescript-app.integtest.ts b/packages/@aws-cdk-testing/cli-integ/tests/init-typescript-app/init-typescript-app.integtest.ts new file mode 100644 index 0000000000000..158764ef3c973 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/tests/init-typescript-app/init-typescript-app.integtest.ts @@ -0,0 +1,58 @@ +import { promises as fs } from 'fs'; +import * as path from 'path'; +import { integTest, withTemporaryDirectory, ShellHelper, withPackages, TemporaryDirectoryContext } from '../../lib'; +import { typescriptVersionsSync } from '../../lib/npm'; + +['app', 'sample-app'].forEach(template => { + integTest(`typescript init ${template}`, withTemporaryDirectory(withPackages(async (context) => { + const shell = ShellHelper.fromContext(context); + await context.packages.makeCliAvailable(); + + await shell.shell(['cdk', 'init', '-l', 'typescript', template]); + + await shell.shell(['npm', 'prune']); + await shell.shell(['npm', 'ls']); // this will fail if we have unmet peer dependencies + await shell.shell(['npm', 'run', 'build']); + await shell.shell(['npm', 'run', 'test']); + + await shell.shell(['cdk', 'synth']); + }))); +}); + +/** + * Test our generated code with various versions of TypeScript + */ +typescriptVersionsSync().forEach(tsVersion => { + integTest(`typescript ${tsVersion} init app`, withTemporaryDirectory(withPackages(async (context) => { + const shell = ShellHelper.fromContext(context); + await context.packages.makeCliAvailable(); + + await shell.shell(['node', '--version']); + await shell.shell(['npm', '--version']); + + await shell.shell(['cdk', 'init', '-l', 'typescript', 'app', '--generate-only']); + + // Necessary because recent versions of ts-jest require TypeScript>=4.3 but we + // still want to test with older versions as well. + await removeDevDependencies(context); + + await shell.shell(['npm', 'install', '--save-dev', `typescript@${tsVersion}`]); + await shell.shell(['npm', 'install']); // Older versions of npm require this to be a separate step from the one above + await shell.shell(['npx', 'tsc', '--version']); + await shell.shell(['npm', 'prune']); + await shell.shell(['npm', 'ls']); // this will fail if we have unmet peer dependencies + + // We just removed the 'jest' dependency so remove the tests as well because they won't compile + await shell.shell(['rm', '-rf', 'test/']); + + await shell.shell(['npm', 'run', 'build']); + await shell.shell(['cdk', 'synth']); + }))); +}); + +async function removeDevDependencies(context: TemporaryDirectoryContext) { + const filename = path.join(context.integTestDir, 'package.json'); + const pj = JSON.parse(await fs.readFile(filename, { encoding: 'utf-8' })); + delete pj.devDependencies; + await fs.writeFile(filename, JSON.stringify(pj, undefined, 2), { encoding: 'utf-8' }); +} \ No newline at end of file diff --git a/packages/@aws-cdk-testing/cli-integ/tests/init-typescript-lib/init-typescript-lib.integtest.ts b/packages/@aws-cdk-testing/cli-integ/tests/init-typescript-lib/init-typescript-lib.integtest.ts new file mode 100644 index 0000000000000..12472c82709cc --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/tests/init-typescript-lib/init-typescript-lib.integtest.ts @@ -0,0 +1,13 @@ +import { integTest, withTemporaryDirectory, ShellHelper, withPackages } from '../../lib'; + +integTest('typescript init lib', withTemporaryDirectory(withPackages(async (context) => { + const shell = ShellHelper.fromContext(context); + await context.packages.makeCliAvailable(); + + await shell.shell(['cdk', 'init', '-l', 'typescript', 'lib']); + + await shell.shell(['npm', 'prune']); + await shell.shell(['npm', 'ls']); // this will fail if we have unmet peer dependencies + await shell.shell(['npm', 'run', 'build']); + await shell.shell(['npm', 'run', 'test']); +}))); \ No newline at end of file diff --git a/packages/aws-cdk/test/integ/uberpackage/uberpackage.integtest.ts b/packages/@aws-cdk-testing/cli-integ/tests/uberpackage/uberpackage.integtest.ts similarity index 69% rename from packages/aws-cdk/test/integ/uberpackage/uberpackage.integtest.ts rename to packages/@aws-cdk-testing/cli-integ/tests/uberpackage/uberpackage.integtest.ts index 6521e4c8113a0..ee924b783f377 100644 --- a/packages/aws-cdk/test/integ/uberpackage/uberpackage.integtest.ts +++ b/packages/@aws-cdk-testing/cli-integ/tests/uberpackage/uberpackage.integtest.ts @@ -1,5 +1,4 @@ -import { withMonolithicCfnIncludeCdkApp } from '../helpers/cdk'; -import { integTest } from '../helpers/test-helpers'; +import { integTest, withMonolithicCfnIncludeCdkApp } from '../../lib'; jest.setTimeout(600_000); diff --git a/packages/@aws-cdk-testing/cli-integ/tsconfig.json b/packages/@aws-cdk-testing/cli-integ/tsconfig.json new file mode 100644 index 0000000000000..f03765e562835 --- /dev/null +++ b/packages/@aws-cdk-testing/cli-integ/tsconfig.json @@ -0,0 +1,26 @@ +{ + "compilerOptions": { + "target": "ES2020", + "module": "commonjs", + "lib": ["es2019", "es2020", "dom"], + "strict": true, + "alwaysStrict": true, + "declaration": true, + "inlineSourceMap": true, + "inlineSources": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noImplicitReturns": true, + "noFallthroughCasesInSwitch": true, + "resolveJsonModule": true, + "composite": true, + "incremental": true + }, + "include": [ + "**/*.ts", + "**/*.d.ts" + ], + "exclude": [ + "resources/**/*" + ] +} diff --git a/packages/@aws-cdk/aws-appsync/README.md b/packages/@aws-cdk/aws-appsync/README.md index 52d041f0c2fe8..815a1b7ab0699 100644 --- a/packages/@aws-cdk/aws-appsync/README.md +++ b/packages/@aws-cdk/aws-appsync/README.md @@ -258,7 +258,7 @@ import * as opensearch from '@aws-cdk/aws-opensearchservice'; const user = new iam.User(this, 'User'); const domain = new opensearch.Domain(this, 'Domain', { - version: opensearch.EngineVersion.OPENSEARCH_1_3, + version: opensearch.EngineVersion.OPENSEARCH_2_3, removalPolicy: RemovalPolicy.DESTROY, fineGrainedAccessControl: { masterUserArn: user.userArn }, encryptionAtRest: { enabled: true }, diff --git a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/appsync-opensearch.assets.json b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/appsync-opensearch.assets.json index a7da3cc32abc0..4779f5cbb1c5c 100644 --- a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/appsync-opensearch.assets.json +++ b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/appsync-opensearch.assets.json @@ -1,7 +1,7 @@ { - "version": "22.0.0", + "version": "29.0.0", "files": { - "cbf69265acb5253067d9fc78cec3e7b151737dc0ba84d10aedd04a2c12f84bc4": { + "f8a2a9f9e0d429354b6c00646ad4364f5e46ab6ceecf270d2ff59b9befcba8b5": { "source": { "path": "appsync-opensearch.template.json", "packaging": "file" @@ -9,7 +9,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "cbf69265acb5253067d9fc78cec3e7b151737dc0ba84d10aedd04a2c12f84bc4.json", + "objectKey": "f8a2a9f9e0d429354b6c00646ad4364f5e46ab6ceecf270d2ff59b9befcba8b5.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/appsync-opensearch.template.json b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/appsync-opensearch.template.json index 9b3b8ea1cb382..d754b3115a94f 100644 --- a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/appsync-opensearch.template.json +++ b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/appsync-opensearch.template.json @@ -36,7 +36,7 @@ "EncryptionAtRestOptions": { "Enabled": true }, - "EngineVersion": "OpenSearch_1.3", + "EngineVersion": "OpenSearch_2.3", "LogPublishingOptions": {}, "NodeToNodeEncryptionOptions": { "Enabled": true diff --git a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/cdk.out b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/cdk.out index 145739f539580..d8b441d447f8a 100644 --- a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/cdk.out +++ b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/cdk.out @@ -1 +1 @@ -{"version":"22.0.0"} \ No newline at end of file +{"version":"29.0.0"} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/integ.json b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/integ.json index 9082fbbe8ed5d..bb6303b9a3102 100644 --- a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/integ.json +++ b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/integ.json @@ -1,14 +1,12 @@ { - "version": "22.0.0", + "version": "29.0.0", "testCases": { - "integ.graphql-opensearch": { + "opensearch-2.3-stack/DefaultTest": { "stacks": [ "appsync-opensearch" ], - "diffAssets": false, - "stackUpdateWorkflow": true + "assertionStack": "opensearch-2.3-stack/DefaultTest/DeployAssert", + "assertionStackName": "opensearch23stackDefaultTestDeployAssert16E12129" } - }, - "synthContext": {}, - "enableLookups": false + } } \ No newline at end of file diff --git a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/manifest.json b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/manifest.json index 81e53a3ee447f..b2fd7635f79eb 100644 --- a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/manifest.json +++ b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/manifest.json @@ -1,5 +1,5 @@ { - "version": "22.0.0", + "version": "29.0.0", "artifacts": { "appsync-opensearch.assets": { "type": "cdk:asset-manifest", @@ -17,7 +17,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/cbf69265acb5253067d9fc78cec3e7b151737dc0ba84d10aedd04a2c12f84bc4.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/f8a2a9f9e0d429354b6c00646ad4364f5e46ab6ceecf270d2ff59b9befcba8b5.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ @@ -98,18 +98,56 @@ "type": "aws:cdk:logicalId", "data": "CheckBootstrapVersion" } + ] + }, + "displayName": "appsync-opensearch" + }, + "opensearch23stackDefaultTestDeployAssert16E12129.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "opensearch23stackDefaultTestDeployAssert16E12129.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "opensearch23stackDefaultTestDeployAssert16E12129": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "opensearch23stackDefaultTestDeployAssert16E12129.template.json", + "validateOnSynth": false, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "opensearch23stackDefaultTestDeployAssert16E12129.assets" ], - "apidsQuerygetTestsResolver5C6FBB59": [ + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "dependencies": [ + "opensearch23stackDefaultTestDeployAssert16E12129.assets" + ], + "metadata": { + "/opensearch-2.3-stack/DefaultTest/DeployAssert/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/opensearch-2.3-stack/DefaultTest/DeployAssert/CheckBootstrapVersion": [ { "type": "aws:cdk:logicalId", - "data": "apidsQuerygetTestsResolver5C6FBB59", - "trace": [ - "!!DESTRUCTIVE_CHANGES: WILL_DESTROY" - ] + "data": "CheckBootstrapVersion" } ] }, - "displayName": "appsync-opensearch" + "displayName": "opensearch-2.3-stack/DefaultTest/DeployAssert" }, "Tree": { "type": "cdk:tree", diff --git a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/opensearch23stackDefaultTestDeployAssert16E12129.assets.json b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/opensearch23stackDefaultTestDeployAssert16E12129.assets.json new file mode 100644 index 0000000000000..b3ad2c593e0e2 --- /dev/null +++ b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/opensearch23stackDefaultTestDeployAssert16E12129.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { + "source": { + "path": "opensearch23stackDefaultTestDeployAssert16E12129.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/opensearch23stackDefaultTestDeployAssert16E12129.template.json b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/opensearch23stackDefaultTestDeployAssert16E12129.template.json new file mode 100644 index 0000000000000..ad9d0fb73d1dd --- /dev/null +++ b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/opensearch23stackDefaultTestDeployAssert16E12129.template.json @@ -0,0 +1,36 @@ +{ + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/tree.json b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/tree.json index 7c9f3a92a3545..038e752c0e9d7 100644 --- a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/tree.json +++ b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.js.snapshot/tree.json @@ -70,7 +70,7 @@ "encryptionAtRestOptions": { "enabled": true }, - "engineVersion": "OpenSearch_1.3", + "engineVersion": "OpenSearch_2.3", "logPublishingOptions": {}, "nodeToNodeEncryptionOptions": { "enabled": true @@ -383,12 +383,66 @@ "version": "0.0.0" } }, + "opensearch-2.3-stack": { + "id": "opensearch-2.3-stack", + "path": "opensearch-2.3-stack", + "children": { + "DefaultTest": { + "id": "DefaultTest", + "path": "opensearch-2.3-stack/DefaultTest", + "children": { + "Default": { + "id": "Default", + "path": "opensearch-2.3-stack/DefaultTest/Default", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.209" + } + }, + "DeployAssert": { + "id": "DeployAssert", + "path": "opensearch-2.3-stack/DefaultTest/DeployAssert", + "children": { + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "opensearch-2.3-stack/DefaultTest/DeployAssert/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "opensearch-2.3-stack/DefaultTest/DeployAssert/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/integ-tests.IntegTestCase", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/integ-tests.IntegTest", + "version": "0.0.0" + } + }, "Tree": { "id": "Tree", "path": "Tree", "constructInfo": { "fqn": "constructs.Construct", - "version": "10.1.182" + "version": "10.1.209" } } }, diff --git a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.ts b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.ts index 67d283b7ca1e6..daf75dad88555 100644 --- a/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.ts +++ b/packages/@aws-cdk/aws-appsync/test/integ.graphql-opensearch.ts @@ -2,65 +2,78 @@ import * as path from 'path'; import { User } from '@aws-cdk/aws-iam'; import * as opensearch from '@aws-cdk/aws-opensearchservice'; import * as cdk from '@aws-cdk/core'; +import { IntegTest } from '@aws-cdk/integ-tests'; +import { Construct } from 'constructs'; import * as appsync from '../lib'; -const app = new cdk.App(); -const stack = new cdk.Stack(app, 'appsync-opensearch'); -const user = new User(stack, 'User'); -const domain = new opensearch.Domain(stack, 'Domain', { - version: opensearch.EngineVersion.OPENSEARCH_1_3, - removalPolicy: cdk.RemovalPolicy.DESTROY, - fineGrainedAccessControl: { - masterUserArn: user.userArn, - }, - encryptionAtRest: { - enabled: true, - }, - nodeToNodeEncryption: true, - enforceHttps: true, -}); - -const api = new appsync.GraphqlApi(stack, 'api', { - name: 'api', - schema: appsync.SchemaFile.fromAsset(path.join(__dirname, 'appsync.test.graphql')), -}); +class OpensSearch23Stack extends cdk.Stack { + constructor(scope: Construct) { + super(scope, 'appsync-opensearch'); -const ds = api.addOpenSearchDataSource('ds', domain); + const user = new User(this, 'User'); -ds.createResolver('QueryGetTests', { - typeName: 'Query', - fieldName: 'getTests', - requestMappingTemplate: appsync.MappingTemplate.fromString(JSON.stringify({ - version: '2017-02-28', - operation: 'GET', - path: '/id/post/_search', - params: { - headers: {}, - queryString: {}, - body: { - from: 0, - size: 50, + const domain = new opensearch.Domain(this, 'Domain', { + version: opensearch.EngineVersion.OPENSEARCH_2_3, + removalPolicy: cdk.RemovalPolicy.DESTROY, + fineGrainedAccessControl: { + masterUserArn: user.userArn, }, - }, - })), - responseMappingTemplate: appsync.MappingTemplate.fromString(JSON.stringify({ - version: '2017-02-28', - operation: 'GET', - path: '/id/post/_search', - params: { - headers: {}, - queryString: {}, - body: { - from: 0, - size: 50, - query: { - term: { - author: '$util.toJson($context.arguments.author)', + encryptionAtRest: { + enabled: true, + }, + nodeToNodeEncryption: true, + enforceHttps: true, + }); + + const api = new appsync.GraphqlApi(this, 'api', { + name: 'api', + schema: appsync.SchemaFile.fromAsset(path.join(__dirname, 'appsync.test.graphql')), + }); + + const ds = api.addOpenSearchDataSource('ds', domain); + + ds.createResolver('QueryGetTests', { + typeName: 'Query', + fieldName: 'getTests', + requestMappingTemplate: appsync.MappingTemplate.fromString(JSON.stringify({ + version: '2017-02-28', + operation: 'GET', + path: '/id/post/_search', + params: { + headers: {}, + queryString: {}, + body: { + from: 0, + size: 50, }, }, - }, - }, - })), + })), + responseMappingTemplate: appsync.MappingTemplate.fromString(JSON.stringify({ + version: '2017-02-28', + operation: 'GET', + path: '/id/post/_search', + params: { + headers: {}, + queryString: {}, + body: { + from: 0, + size: 50, + query: { + term: { + author: '$util.toJson($context.arguments.author)', + }, + }, + }, + }, + })), + }); + } +} + +const app = new cdk.App(); +const testCase = new OpensSearch23Stack(app); +new IntegTest(app, 'opensearch-2.3-stack', { + testCases: [testCase], }); app.synth(); diff --git a/packages/@aws-cdk/aws-ecs/README.md b/packages/@aws-cdk/aws-ecs/README.md index afbbd0dec4906..080187d9a6ff1 100644 --- a/packages/@aws-cdk/aws-ecs/README.md +++ b/packages/@aws-cdk/aws-ecs/README.md @@ -518,8 +518,8 @@ taskDefinition.addContainer('container', { memoryLimitMiB: 1024, systemControls: [ { - namespace: 'net', - value: 'ipv4.tcp_tw_recycle', + namespace: 'net.ipv6.conf.all.default.disable_ipv6', + value: '1', }, ], }); diff --git a/packages/@aws-cdk/aws-lambda/lib/function-hash.ts b/packages/@aws-cdk/aws-lambda/lib/function-hash.ts index a1b20a8e4dac3..48e7553682948 100644 --- a/packages/@aws-cdk/aws-lambda/lib/function-hash.ts +++ b/packages/@aws-cdk/aws-lambda/lib/function-hash.ts @@ -1,10 +1,10 @@ -import { CfnResource, FeatureFlags, Stack } from '@aws-cdk/core'; +import { CfnResource, FeatureFlags, Stack, Token } from '@aws-cdk/core'; import { md5hash } from '@aws-cdk/core/lib/helpers-internal'; import { LAMBDA_RECOGNIZE_LAYER_VERSION, LAMBDA_RECOGNIZE_VERSION_PROPS } from '@aws-cdk/cx-api'; import { Function as LambdaFunction } from './function'; import { ILayerVersion } from './layers'; -export function calculateFunctionHash(fn: LambdaFunction) { +export function calculateFunctionHash(fn: LambdaFunction, additional: string = '') { const stack = Stack.of(fn); const functionResource = fn.node.defaultChild as CfnResource; @@ -34,7 +34,7 @@ export function calculateFunctionHash(fn: LambdaFunction) { stringifiedConfig = stringifiedConfig + calculateLayersHash(fn._layers); } - return md5hash(stringifiedConfig); + return md5hash(stringifiedConfig + additional); } export function trimFromStart(s: string, maxLength: number) { @@ -130,7 +130,16 @@ function calculateLayersHash(layers: ILayerVersion[]): string { // if there is no layer resource, then the layer was imported // and we will include the layer arn and runtimes in the hash if (layerResource === undefined) { - layerConfig[layer.layerVersionArn] = layer.compatibleRuntimes; + // ARN may have unresolved parts in it, but we didn't deal with this previously + // so deal with it now for backwards compatibility. + if (!Token.isUnresolved(layer.layerVersionArn)) { + layerConfig[layer.layerVersionArn] = layer.compatibleRuntimes; + } else { + layerConfig[layer.node.id] = { + arn: stack.resolve(layer.layerVersionArn), + runtimes: layer.compatibleRuntimes?.map(r => r.name), + }; + } continue; } const config = stack.resolve((layerResource as any)._toCloudFormation()); diff --git a/packages/@aws-cdk/aws-lambda/lib/function.ts b/packages/@aws-cdk/aws-lambda/lib/function.ts index ced52e6cb5459..a998fad63ae57 100644 --- a/packages/@aws-cdk/aws-lambda/lib/function.ts +++ b/packages/@aws-cdk/aws-lambda/lib/function.ts @@ -436,7 +436,7 @@ export class Function extends FunctionBase { cfn.overrideLogicalId(Lazy.uncachedString({ produce: () => { - const hash = calculateFunctionHash(this); + const hash = calculateFunctionHash(this, this.hashMixins.join('')); const logicalId = trimFromStart(originalLogicalId, 255 - 32); return `${logicalId}${hash}`; }, @@ -664,6 +664,7 @@ export class Function extends FunctionBase { private _currentVersion?: Version; private _architecture?: Architecture; + private hashMixins = new Array(); constructor(scope: Construct, id: string, props: FunctionProps) { super(scope, id, { @@ -940,6 +941,31 @@ export class Function extends FunctionBase { return this; } + /** + * Mix additional information into the hash of the Version object + * + * The Lambda Function construct does its best to automatically create a new + * Version when anything about the Function changes (its code, its layers, + * any of the other properties). + * + * However, you can sometimes source information from places that the CDK cannot + * look into, like the deploy-time values of SSM parameters. In those cases, + * the CDK would not force the creation of a new Version object when it actually + * should. + * + * This method can be used to invalidate the current Version object. Pass in + * any string into this method, and make sure the string changes when you know + * a new Version needs to be created. + * + * This method may be called more than once. + */ + public invalidateVersionBasedOn(x: string) { + if (Token.isUnresolved(x)) { + throw new Error('invalidateVersionOn: input may not contain unresolved tokens'); + } + this.hashMixins.push(x); + } + /** * Adds one or more Lambda Layers to this Lambda function. * diff --git a/packages/@aws-cdk/aws-lambda/package.json b/packages/@aws-cdk/aws-lambda/package.json index f7191f7ed90e6..2eb719312000f 100644 --- a/packages/@aws-cdk/aws-lambda/package.json +++ b/packages/@aws-cdk/aws-lambda/package.json @@ -94,6 +94,7 @@ "@types/aws-lambda": "^8.10.109", "@types/jest": "^27.5.2", "@types/lodash": "^4.14.191", + "@aws-cdk/aws-ssm": "0.0.0", "jest": "^27.5.1", "lodash": "^4.17.21" }, diff --git a/packages/@aws-cdk/aws-lambda/test/function-hash.test.ts b/packages/@aws-cdk/aws-lambda/test/function-hash.test.ts index cf4e0e953faa0..9cff57419184f 100644 --- a/packages/@aws-cdk/aws-lambda/test/function-hash.test.ts +++ b/packages/@aws-cdk/aws-lambda/test/function-hash.test.ts @@ -1,4 +1,6 @@ import * as path from 'path'; +import { Template } from '@aws-cdk/assertions'; +import * as ssm from '@aws-cdk/aws-ssm'; import { resourceSpecification } from '@aws-cdk/cfnspec'; import { App, CfnOutput, CfnResource, Stack } from '@aws-cdk/core'; import * as cxapi from '@aws-cdk/cx-api'; @@ -440,3 +442,84 @@ describe('function hash', () => { }); }); }); + +test('imported layer hashes are consistent', () => { + // GIVEN + const app = new App({ + context: { + '@aws-cdk/aws-lambda:recognizeLayerVersion': true, + }, + }); + + // WHEN + const stack1 = new Stack(app, 'Stack1'); + const param1 = ssm.StringParameter.fromStringParameterName(stack1, 'Param', 'ParamName'); + const fn1 = new lambda.Function(stack1, 'Fn', { + code: lambda.Code.fromInline('asdf'), + handler: 'index.handler', + runtime: lambda.Runtime.NODEJS_18_X, + layers: [ + lambda.LayerVersion.fromLayerVersionArn(stack1, 'MyLayer', + `arn:aws:lambda:${stack1.region}::layer:IndexCFN:${param1.stringValue}`), + ], + }); + fn1.currentVersion; // Force creation of version + + const stack2 = new Stack(app, 'Stack2'); + const param2 = ssm.StringParameter.fromStringParameterName(stack2, 'Param', 'ParamName'); + const fn2 = new lambda.Function(stack2, 'Fn', { + code: lambda.Code.fromInline('asdf'), + handler: 'index.handler', + runtime: lambda.Runtime.NODEJS_18_X, + layers: [ + lambda.LayerVersion.fromLayerVersionArn(stack2, 'MyLayer', + `arn:aws:lambda:${stack1.region}::layer:IndexCFN:${param2.stringValue}`), + ], + }); + fn2.currentVersion; // Force creation of version + + // THEN + const template1 = Template.fromStack(stack1); + const template2 = Template.fromStack(stack2); + + expect(template1.toJSON()).toEqual(template2.toJSON()); +}); + +test.each([false, true])('can invalidate version hash using invalidateVersionBasedOn: %p', (doIt) => { + // GIVEN + const app = new App(); + + // WHEN + const stack1 = new Stack(app, 'Stack1'); + const fn1 = new lambda.Function(stack1, 'Fn', { + code: lambda.Code.fromInline('asdf'), + handler: 'index.handler', + runtime: lambda.Runtime.NODEJS_18_X, + }); + if (doIt) { + fn1.invalidateVersionBasedOn('abc'); + } + fn1.currentVersion; // Force creation of version + + const stack2 = new Stack(app, 'Stack2'); + const fn2 = new lambda.Function(stack2, 'Fn', { + code: lambda.Code.fromInline('asdf'), + handler: 'index.handler', + runtime: lambda.Runtime.NODEJS_18_X, + }); + if (doIt) { + fn1.invalidateVersionBasedOn('xyz'); + } + fn2.currentVersion; // Force creation of version + + // THEN + const template1 = Template.fromStack(stack1); + const template2 = Template.fromStack(stack2); + + if (doIt) { + expect(template1.toJSON()).not.toEqual(template2.toJSON()); + } else { + expect(template1.toJSON()).toEqual(template2.toJSON()); + } + +}); \ No newline at end of file diff --git a/packages/@aws-cdk/aws-opensearchservice/lib/version.ts b/packages/@aws-cdk/aws-opensearchservice/lib/version.ts index 0347159408023..55a861a3518f9 100644 --- a/packages/@aws-cdk/aws-opensearchservice/lib/version.ts +++ b/packages/@aws-cdk/aws-opensearchservice/lib/version.ts @@ -71,6 +71,16 @@ export class EngineVersion { /** AWS OpenSearch 1.3 */ public static readonly OPENSEARCH_1_3 = EngineVersion.openSearch('1.3'); + /** + * AWS OpenSearch 2.3 + * + * OpenSearch 2.3 is now available on Amazon OpenSearch Service across 26 + * regions globally. Please refer to the AWS Region Table for more + * information about Amazon OpenSearch Service availability: + * https://aws.amazon.com/about-aws/global-infrastructure/regional-product-services/ + * */ + public static readonly OPENSEARCH_2_3 = EngineVersion.openSearch('2.3'); + /** * Custom ElasticSearch version * @param version custom version number diff --git a/packages/@aws-cdk/aws-opensearchservice/package.json b/packages/@aws-cdk/aws-opensearchservice/package.json index a18f45d1c3b65..448c286bcfa09 100644 --- a/packages/@aws-cdk/aws-opensearchservice/package.json +++ b/packages/@aws-cdk/aws-opensearchservice/package.json @@ -91,7 +91,8 @@ "@aws-cdk/pkglint": "0.0.0", "@aws-cdk/integ-tests": "0.0.0", "@aws-cdk/aws-cognito": "0.0.0", - "@types/jest": "^27.5.2" + "@types/jest": "^27.5.2", + "jest-each": "^27.5.1" }, "dependencies": { "@aws-cdk/aws-certificatemanager": "0.0.0", diff --git a/packages/@aws-cdk/aws-opensearchservice/test/domain.test.ts b/packages/@aws-cdk/aws-opensearchservice/test/domain.test.ts index 6e983d88baf7e..76ee62713c58c 100644 --- a/packages/@aws-cdk/aws-opensearchservice/test/domain.test.ts +++ b/packages/@aws-cdk/aws-opensearchservice/test/domain.test.ts @@ -8,6 +8,7 @@ import * as kms from '@aws-cdk/aws-kms'; import * as logs from '@aws-cdk/aws-logs'; import * as route53 from '@aws-cdk/aws-route53'; import { App, Stack, Duration, SecretValue, CfnParameter, Token } from '@aws-cdk/core'; +import each from 'jest-each'; import { Domain, EngineVersion } from '../lib'; let app: App; @@ -29,25 +30,31 @@ const readWriteActions = [ ...writeActions, ]; -const defaultVersion = EngineVersion.OPENSEARCH_1_0; +const testedOpenSearchVersions = [ + EngineVersion.OPENSEARCH_1_0, + EngineVersion.OPENSEARCH_1_1, + EngineVersion.OPENSEARCH_1_2, + EngineVersion.OPENSEARCH_1_3, + EngineVersion.OPENSEARCH_2_3, +]; -test('connections throws if domain is not placed inside a vpc', () => { +each(testedOpenSearchVersions).test('connections throws if domain is not placed inside a vpc', (engineVersion) => { expect(() => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, }).connections; }).toThrowError("Connections are only available on VPC enabled domains. Use the 'vpc' property to place a domain inside a VPC"); }); -test('subnets and security groups can be provided when vpc is used', () => { +each(testedOpenSearchVersions).test('subnets and security groups can be provided when vpc is used', (engineVersion) => { const vpc = new Vpc(stack, 'Vpc'); const securityGroup = new SecurityGroup(stack, 'CustomSecurityGroup', { vpc, }); const domain = new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, vpc, vpcSubnets: [{ subnets: [vpc.privateSubnets[0]] }], securityGroups: [securityGroup], @@ -74,11 +81,11 @@ test('subnets and security groups can be provided when vpc is used', () => { }); -test('default subnets and security group when vpc is used', () => { +each(testedOpenSearchVersions).test('default subnets and security group when vpc is used', (engineVersion) => { const vpc = new Vpc(stack, 'Vpc'); const domain = new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, vpc, }); @@ -109,11 +116,11 @@ test('default subnets and security group when vpc is used', () => { }); -test('connections has no default port if enforceHttps is false', () => { +each(testedOpenSearchVersions).test('connections has no default port if enforceHttps is false', (engineVersion) => { const vpc = new Vpc(stack, 'Vpc'); const domain = new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, vpc, enforceHttps: false, }); @@ -122,11 +129,11 @@ test('connections has no default port if enforceHttps is false', () => { }); -test('connections has default port 443 if enforceHttps is true', () => { +each(testedOpenSearchVersions).test('connections has default port 443 if enforceHttps is true', (engineVersion) => { const vpc = new Vpc(stack, 'Vpc'); const domain = new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, vpc, enforceHttps: true, }); @@ -135,9 +142,9 @@ test('connections has default port 443 if enforceHttps is true', () => { }); -test('default removalpolicy is retain', () => { +each(testedOpenSearchVersions).test('default removalpolicy is retain', (engineVersion) => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, }); Template.fromStack(stack).hasResource('AWS::OpenSearchService::Domain', { @@ -145,12 +152,12 @@ test('default removalpolicy is retain', () => { }); }); -test('grants kms permissions if needed', () => { +each([testedOpenSearchVersions]).test('grants kms permissions if needed', (engineVersion) => { const key = new kms.Key(stack, 'Key'); new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, encryptionAtRest: { kmsKey: key, }, @@ -183,8 +190,14 @@ test('grants kms permissions if needed', () => { }); -test('minimal example renders correctly', () => { - new Domain(stack, 'Domain', { version: defaultVersion }); +each([ + [EngineVersion.OPENSEARCH_1_0, 'OpenSearch_1.0'], + [EngineVersion.OPENSEARCH_1_1, 'OpenSearch_1.1'], + [EngineVersion.OPENSEARCH_1_2, 'OpenSearch_1.2'], + [EngineVersion.OPENSEARCH_1_3, 'OpenSearch_1.3'], + [EngineVersion.OPENSEARCH_2_3, 'OpenSearch_2.3'], +]).test('minimal example renders correctly', (engineVersion, expectedCfVersion) => { + new Domain(stack, 'Domain', { version: engineVersion }); Template.fromStack(stack).hasResourceProperties('AWS::OpenSearchService::Domain', { EBSOptions: { @@ -198,7 +211,7 @@ test('minimal example renders correctly', () => { InstanceType: 'r5.large.search', ZoneAwarenessEnabled: false, }, - EngineVersion: 'OpenSearch_1.0', + EngineVersion: expectedCfVersion, EncryptionAtRestOptions: { Enabled: false, }, @@ -214,9 +227,9 @@ test('minimal example renders correctly', () => { }); }); -test('can enable version upgrade update policy', () => { +each([testedOpenSearchVersions]).test('can enable version upgrade update policy', (engineVersion) => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, enableVersionUpgrade: true, }); @@ -227,9 +240,9 @@ test('can enable version upgrade update policy', () => { }); }); -test('can set a self-referencing custom policy', () => { +each([testedOpenSearchVersions]).test('can set a self-referencing custom policy', (engineVersion) => { const domain = new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, }); domain.addAccessPolicies( @@ -287,11 +300,11 @@ test('can set a self-referencing custom policy', () => { }); }); -describe('UltraWarm instances', () => { +each([testedOpenSearchVersions]).describe('UltraWarm instances', (engineVersion) => { test('can enable UltraWarm instances', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, capacity: { masterNodes: 2, warmNodes: 2, @@ -310,7 +323,7 @@ describe('UltraWarm instances', () => { test('can enable UltraWarm instances with specific instance type', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, capacity: { masterNodes: 2, warmNodes: 2, @@ -330,9 +343,9 @@ describe('UltraWarm instances', () => { }); -test('can use tokens in capacity configuration', () => { +each([testedOpenSearchVersions]).test('can use tokens in capacity configuration', (engineVersion) => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, capacity: { dataNodeInstanceType: Token.asString({ Ref: 'dataNodeInstanceType' }), dataNodes: Token.asNumber({ Ref: 'dataNodes' }), @@ -369,11 +382,11 @@ test('can use tokens in capacity configuration', () => { }); }); -describe('log groups', () => { +each([testedOpenSearchVersions]).describe('log groups', (engineVersion) => { test('slowSearchLogEnabled should create a custom log group', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, logging: { slowSearchLogEnabled: true, }, @@ -399,7 +412,7 @@ describe('log groups', () => { test('slowIndexLogEnabled should create a custom log group', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, logging: { slowIndexLogEnabled: true, }, @@ -425,7 +438,7 @@ describe('log groups', () => { test('appLogEnabled should create a custom log group', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, logging: { appLogEnabled: true, }, @@ -451,7 +464,7 @@ describe('log groups', () => { test('auditLogEnabled should create a custom log group', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, logging: { auditLogEnabled: true, }, @@ -485,7 +498,7 @@ describe('log groups', () => { test('two domains with logging enabled can be created in same stack', () => { new Domain(stack, 'Domain1', { - version: defaultVersion, + version: engineVersion, logging: { appLogEnabled: true, slowSearchLogEnabled: true, @@ -493,7 +506,7 @@ describe('log groups', () => { }, }); new Domain(stack, 'Domain2', { - version: defaultVersion, + version: engineVersion, logging: { appLogEnabled: true, slowSearchLogEnabled: true, @@ -568,13 +581,13 @@ describe('log groups', () => { test('log group policy is uniquely named for each domain', () => { new Domain(stack, 'Domain1', { - version: defaultVersion, + version: engineVersion, logging: { appLogEnabled: true, }, }); new Domain(stack, 'Domain2', { - version: defaultVersion, + version: engineVersion, logging: { appLogEnabled: true, }, @@ -620,7 +633,7 @@ describe('log groups', () => { test('enabling audit logs throws without fine grained access control enabled', () => { expect(() => new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, logging: { auditLogEnabled: true, }, @@ -629,7 +642,7 @@ describe('log groups', () => { test('slowSearchLogGroup should use a custom log group', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, logging: { slowSearchLogEnabled: true, slowSearchLogGroup: new logs.LogGroup(stack, 'SlowSearchLogs', { @@ -658,7 +671,7 @@ describe('log groups', () => { test('slowIndexLogEnabled should use a custom log group', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, logging: { slowIndexLogEnabled: true, slowIndexLogGroup: new logs.LogGroup(stack, 'SlowIndexLogs', { @@ -687,7 +700,7 @@ describe('log groups', () => { test('appLogGroup should use a custom log group', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, logging: { appLogEnabled: true, appLogGroup: new logs.LogGroup(stack, 'AppLogs', { @@ -716,7 +729,7 @@ describe('log groups', () => { test('auditLOgGroup should use a custom log group', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, fineGrainedAccessControl: { masterUserName: 'username', }, @@ -753,24 +766,25 @@ describe('log groups', () => { }); -describe('grants', () => { +each(testedOpenSearchVersions).describe('grants', (engineVersion) => { test('"grantRead" allows read actions associated with this domain resource', () => { - testGrant(readActions, (p, d) => d.grantRead(p)); + testGrant(readActions, (p, d) => d.grantRead(p), engineVersion); }); test('"grantWrite" allows write actions associated with this domain resource', () => { - testGrant(writeActions, (p, d) => d.grantWrite(p)); + testGrant(writeActions, (p, d) => d.grantWrite(p), engineVersion); }); test('"grantReadWrite" allows read and write actions associated with this domain resource', () => { - testGrant(readWriteActions, (p, d) => d.grantReadWrite(p)); + testGrant(readWriteActions, (p, d) => d.grantReadWrite(p), engineVersion); }); test('"grantIndexRead" allows read actions associated with an index in this domain resource', () => { testGrant( readActions, (p, d) => d.grantIndexRead('my-index', p), + engineVersion, false, ['/my-index', '/my-index/*'], ); @@ -780,6 +794,7 @@ describe('grants', () => { testGrant( writeActions, (p, d) => d.grantIndexWrite('my-index', p), + engineVersion, false, ['/my-index', '/my-index/*'], ); @@ -789,6 +804,7 @@ describe('grants', () => { testGrant( readWriteActions, (p, d) => d.grantIndexReadWrite('my-index', p), + engineVersion, false, ['/my-index', '/my-index/*'], ); @@ -798,6 +814,7 @@ describe('grants', () => { testGrant( readActions, (p, d) => d.grantPathRead('my-index/my-path', p), + engineVersion, false, ['/my-index/my-path'], ); @@ -807,6 +824,7 @@ describe('grants', () => { testGrant( writeActions, (p, d) => d.grantPathWrite('my-index/my-path', p), + engineVersion, false, ['/my-index/my-path'], ); @@ -816,6 +834,7 @@ describe('grants', () => { testGrant( readWriteActions, (p, d) => d.grantPathReadWrite('my-index/my-path', p), + engineVersion, false, ['/my-index/my-path'], ); @@ -882,12 +901,13 @@ describe('grants', () => { }); -describe('metrics', () => { +each(testedOpenSearchVersions).describe('metrics', (engineVersion) => { test('metricClusterStatusRed', () => { testMetric( (domain) => domain.metricClusterStatusRed(), 'ClusterStatus.red', + engineVersion, Statistic.MAXIMUM, ); }); @@ -896,6 +916,7 @@ describe('metrics', () => { testMetric( (domain) => domain.metricClusterStatusYellow(), 'ClusterStatus.yellow', + engineVersion, Statistic.MAXIMUM, ); }); @@ -904,6 +925,7 @@ describe('metrics', () => { testMetric( (domain) => domain.metricFreeStorageSpace(), 'FreeStorageSpace', + engineVersion, Statistic.MINIMUM, ); }); @@ -912,6 +934,7 @@ describe('metrics', () => { testMetric( (domain) => domain.metricClusterIndexWritesBlocked(), 'ClusterIndexWritesBlocked', + engineVersion, Statistic.MAXIMUM, Duration.minutes(1), ); @@ -921,6 +944,7 @@ describe('metrics', () => { testMetric( (domain) => domain.metricNodes(), 'Nodes', + engineVersion, Statistic.MINIMUM, Duration.hours(1), ); @@ -930,6 +954,7 @@ describe('metrics', () => { testMetric( (domain) => domain.metricAutomatedSnapshotFailure(), 'AutomatedSnapshotFailure', + engineVersion, Statistic.MAXIMUM, ); }); @@ -938,6 +963,7 @@ describe('metrics', () => { testMetric( (domain) => domain.metricCPUUtilization(), 'CPUUtilization', + engineVersion, Statistic.MAXIMUM, ); }); @@ -946,6 +972,7 @@ describe('metrics', () => { testMetric( (domain) => domain.metricJVMMemoryPressure(), 'JVMMemoryPressure', + engineVersion, Statistic.MAXIMUM, ); }); @@ -954,6 +981,7 @@ describe('metrics', () => { testMetric( (domain) => domain.metricMasterCPUUtilization(), 'MasterCPUUtilization', + engineVersion, Statistic.MAXIMUM, ); }); @@ -962,6 +990,7 @@ describe('metrics', () => { testMetric( (domain) => domain.metricMasterJVMMemoryPressure(), 'MasterJVMMemoryPressure', + engineVersion, Statistic.MAXIMUM, ); }); @@ -970,6 +999,7 @@ describe('metrics', () => { testMetric( (domain) => domain.metricKMSKeyError(), 'KMSKeyError', + engineVersion, Statistic.MAXIMUM, ); }); @@ -978,6 +1008,7 @@ describe('metrics', () => { testMetric( (domain) => domain.metricKMSKeyInaccessible(), 'KMSKeyInaccessible', + engineVersion, Statistic.MAXIMUM, ); }); @@ -986,6 +1017,7 @@ describe('metrics', () => { testMetric( (domain) => domain.metricSearchableDocuments(), 'SearchableDocuments', + engineVersion, Statistic.MAXIMUM, ); }); @@ -994,6 +1026,7 @@ describe('metrics', () => { testMetric( (domain) => domain.metricSearchLatency(), 'SearchLatency', + engineVersion, 'p99', ); }); @@ -1002,6 +1035,7 @@ describe('metrics', () => { testMetric( (domain) => domain.metricIndexingLatency(), 'IndexingLatency', + engineVersion, 'p99', ); }); @@ -1079,7 +1113,7 @@ describe('import', () => { }); }); -describe('advanced security options', () => { +each(testedOpenSearchVersions).describe('advanced security options', (engineVersion) => { const masterUserArn = 'arn:aws:iam::123456789012:user/JohnDoe'; const masterUserName = 'JohnDoe'; const password = 'password'; @@ -1087,7 +1121,7 @@ describe('advanced security options', () => { test('enable fine-grained access control with a master user ARN', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, fineGrainedAccessControl: { masterUserArn, }, @@ -1120,7 +1154,7 @@ describe('advanced security options', () => { test('enable fine-grained access control with a master user name and password', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, fineGrainedAccessControl: { masterUserName, masterUserPassword, @@ -1155,7 +1189,7 @@ describe('advanced security options', () => { test('enable fine-grained access control with a master user name and dynamically generated password', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, fineGrainedAccessControl: { masterUserName, }, @@ -1220,7 +1254,7 @@ describe('advanced security options', () => { test('enabling fine-grained access control throws without node-to-node encryption enabled', () => { expect(() => new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, fineGrainedAccessControl: { masterUserArn, }, @@ -1234,7 +1268,7 @@ describe('advanced security options', () => { test('enabling fine-grained access control throws without encryption-at-rest enabled', () => { expect(() => new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, fineGrainedAccessControl: { masterUserArn, }, @@ -1248,7 +1282,7 @@ describe('advanced security options', () => { test('enabling fine-grained access control throws without enforceHttps enabled', () => { expect(() => new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, fineGrainedAccessControl: { masterUserArn, }, @@ -1261,12 +1295,12 @@ describe('advanced security options', () => { }); }); -describe('custom endpoints', () => { +each(testedOpenSearchVersions).describe('custom endpoints', (engineVersion) => { const customDomainName = 'search.example.com'; test('custom domain without hosted zone and default cert', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, nodeToNodeEncryption: true, enforceHttps: true, customEndpoint: { @@ -1293,7 +1327,7 @@ describe('custom endpoints', () => { test('custom domain with hosted zone and default cert', () => { const zone = new route53.HostedZone(stack, 'DummyZone', { zoneName: 'example.com' }); new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, nodeToNodeEncryption: true, enforceHttps: true, customEndpoint: { @@ -1350,7 +1384,7 @@ describe('custom endpoints', () => { }); new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, nodeToNodeEncryption: true, enforceHttps: true, customEndpoint: { @@ -1389,7 +1423,7 @@ describe('custom endpoints', () => { }); -describe('custom error responses', () => { +each(testedOpenSearchVersions).describe('custom error responses', (engineVersion) => { test('error when availabilityZoneCount does not match vpcOptions.subnets length', () => { const vpc = new Vpc(stack, 'Vpc', { @@ -1397,7 +1431,7 @@ describe('custom error responses', () => { }); expect(() => new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, zoneAwareness: { enabled: true, availabilityZoneCount: 2, @@ -1415,7 +1449,7 @@ describe('custom error responses', () => { }); new Domain(stack, 'Domain1', { - version: defaultVersion, + version: engineVersion, vpc, vpcSubnets: [subnets], zoneAwareness: { @@ -1430,19 +1464,19 @@ describe('custom error responses', () => { test('error when master, data or Ultra Warm instance types do not end with .search', () => { const error = /instance types must end with ".search"/; expect(() => new Domain(stack, 'Domain1', { - version: defaultVersion, + version: engineVersion, capacity: { masterNodeInstanceType: 'c5.large', }, })).toThrow(error); expect(() => new Domain(stack, 'Domain2', { - version: defaultVersion, + version: engineVersion, capacity: { dataNodeInstanceType: 'c5.2xlarge', }, })).toThrow(error); expect(() => new Domain(stack, 'Domain3', { - version: defaultVersion, + version: engineVersion, capacity: { warmInstanceType: 'ultrawarm1.medium', }, @@ -1452,7 +1486,7 @@ describe('custom error responses', () => { test('error when Ultra Warm instance types do not start with ultrawarm', () => { const error = /UltraWarm node instance type must start with "ultrawarm"./; expect(() => new Domain(stack, 'Domain1', { - version: defaultVersion, + version: engineVersion, capacity: { warmInstanceType: 't3.small.search', }, @@ -1548,7 +1582,7 @@ describe('custom error responses', () => { test('error when i3 or r6g instance types are specified with EBS enabled', () => { expect(() => new Domain(stack, 'Domain1', { - version: defaultVersion, + version: engineVersion, capacity: { dataNodeInstanceType: 'i3.2xlarge.search', }, @@ -1558,7 +1592,7 @@ describe('custom error responses', () => { }, })).toThrow(/I3 and R6GD instance types do not support EBS storage volumes/); expect(() => new Domain(stack, 'Domain2', { - version: defaultVersion, + version: engineVersion, capacity: { dataNodeInstanceType: 'r6gd.large.search', }, @@ -1572,7 +1606,7 @@ describe('custom error responses', () => { test('error when m3, r3, or t2 instance types are specified with encryption at rest enabled', () => { const error = /M3, R3, and T2 instance types do not support encryption of data at rest/; expect(() => new Domain(stack, 'Domain1', { - version: defaultVersion, + version: engineVersion, capacity: { masterNodeInstanceType: 'm3.2xlarge.search', }, @@ -1581,7 +1615,7 @@ describe('custom error responses', () => { }, })).toThrow(error); expect(() => new Domain(stack, 'Domain2', { - version: defaultVersion, + version: engineVersion, capacity: { dataNodeInstanceType: 'r3.2xlarge.search', }, @@ -1590,7 +1624,7 @@ describe('custom error responses', () => { }, })).toThrow(error); expect(() => new Domain(stack, 'Domain3', { - version: defaultVersion, + version: engineVersion, capacity: { masterNodeInstanceType: 't2.2xlarge.search', }, @@ -1602,7 +1636,7 @@ describe('custom error responses', () => { test('error when t2.micro is specified with Elasticsearch version > 2.3', () => { expect(() => new Domain(stack, 'Domain1', { - version: defaultVersion, + version: engineVersion, capacity: { masterNodeInstanceType: 't2.micro.search', }, @@ -1611,7 +1645,7 @@ describe('custom error responses', () => { test('error when any instance type other than R3, I3 and R6GD are specified without EBS enabled', () => { expect(() => new Domain(stack, 'Domain1', { - version: defaultVersion, + version: engineVersion, ebs: { enabled: false, }, @@ -1620,7 +1654,7 @@ describe('custom error responses', () => { }, })).toThrow(/EBS volumes are required when using instance types other than r3, i3 or r6gd/); expect(() => new Domain(stack, 'Domain2', { - version: defaultVersion, + version: engineVersion, ebs: { enabled: false, }, @@ -1632,7 +1666,7 @@ describe('custom error responses', () => { test('can use compatible master instance types that does not have local storage when data node type is i3 or r6gd', () => { new Domain(stack, 'Domain1', { - version: defaultVersion, + version: engineVersion, ebs: { enabled: false, }, @@ -1642,7 +1676,7 @@ describe('custom error responses', () => { }, }); new Domain(stack, 'Domain2', { - version: defaultVersion, + version: engineVersion, ebs: { enabled: false, }, @@ -1660,7 +1694,7 @@ describe('custom error responses', () => { const vpc = new Vpc(stack, 'Vpc'); expect(() => new Domain(stack, 'Domain1', { - version: defaultVersion, + version: engineVersion, vpc, zoneAwareness: { availabilityZoneCount: 4, @@ -1681,14 +1715,14 @@ describe('custom error responses', () => { test('error when t2 or t3 instance types are specified with UltramWarm enabled', () => { const error = /T2 and T3 instance types do not support UltraWarm storage/; expect(() => new Domain(stack, 'Domain1', { - version: defaultVersion, + version: engineVersion, capacity: { masterNodeInstanceType: 't2.2xlarge.search', warmNodes: 1, }, })).toThrow(error); expect(() => new Domain(stack, 'Domain2', { - version: defaultVersion, + version: engineVersion, capacity: { masterNodeInstanceType: 't3.2xlarge.search', warmNodes: 1, @@ -1698,7 +1732,7 @@ describe('custom error responses', () => { test('error when UltraWarm instance is used and no dedicated master instance specified', () => { expect(() => new Domain(stack, 'Domain1', { - version: defaultVersion, + version: engineVersion, capacity: { warmNodes: 1, masterNodes: 0, @@ -1716,10 +1750,10 @@ test('can specify future version', () => { }); }); -describe('unsigned basic auth', () => { +each(testedOpenSearchVersions).describe('unsigned basic auth', (engineVersion) => { test('can create a domain with unsigned basic auth', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, useUnsignedBasicAuth: true, }); @@ -1747,7 +1781,7 @@ describe('unsigned basic auth', () => { const masterUserArn = 'arn:aws:iam::123456789012:user/JohnDoe'; new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, fineGrainedAccessControl: { masterUserArn, }, @@ -1780,7 +1814,7 @@ describe('unsigned basic auth', () => { const masterUserPassword = SecretValue.unsafePlainText(password); new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, fineGrainedAccessControl: { masterUserName, masterUserPassword, @@ -1811,7 +1845,7 @@ describe('unsigned basic auth', () => { test('fails to create a domain with unsigned basic auth when enforce HTTPS is disabled', () => { expect(() => new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, useUnsignedBasicAuth: true, enforceHttps: false, })).toThrow(/You cannot disable HTTPS and use unsigned basic auth/); @@ -1819,7 +1853,7 @@ describe('unsigned basic auth', () => { test('fails to create a domain with unsigned basic auth when node to node encryption is disabled', () => { expect(() => new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, useUnsignedBasicAuth: true, nodeToNodeEncryption: false, })).toThrow(/You cannot disable node to node encryption and use unsigned basic auth/); @@ -1827,7 +1861,7 @@ describe('unsigned basic auth', () => { test('fails to create a domain with unsigned basic auth when encryption at rest is disabled', () => { expect(() => new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, useUnsignedBasicAuth: true, encryptionAtRest: { enabled: false }, })).toThrow(/You cannot disable encryption at rest and use unsigned basic auth/); @@ -1841,10 +1875,10 @@ describe('unsigned basic auth', () => { }); }); -describe('advanced options', () => { +each(testedOpenSearchVersions).describe('advanced options', (engineVersion) => { test('use advanced options', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, advancedOptions: { 'rest.action.multi.allow_explicit_index': 'true', 'indices.fielddata.cache.size': '50', @@ -1861,7 +1895,7 @@ describe('advanced options', () => { test('advanced options absent by default', () => { new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, }); Template.fromStack(stack).hasResourceProperties('AWS::OpenSearchService::Domain', { @@ -1870,9 +1904,9 @@ describe('advanced options', () => { }); }); -describe('cognito dashboards auth', () => { +each(testedOpenSearchVersions).describe('cognito dashboards auth', (engineVersion) => { test('cognito dashboards auth is not configured by default', () => { - new Domain(stack, 'Domain', { version: defaultVersion }); + new Domain(stack, 'Domain', { version: engineVersion }); Template.fromStack(stack).hasResourceProperties('AWS::OpenSearchService::Domain', { CognitoOptions: Match.absent(), @@ -1886,7 +1920,7 @@ describe('cognito dashboards auth', () => { const role = new iam.Role(stack, 'testrole', { assumedBy: user }); new Domain(stack, 'Domain', { - version: defaultVersion, + version: engineVersion, cognitoDashboardsAuth: { role, identityPoolId, @@ -1913,10 +1947,11 @@ describe('cognito dashboards auth', () => { function testGrant( expectedActions: string[], invocation: (user: iam.IPrincipal, domain: Domain) => void, + engineVersion: EngineVersion, appliesToDomainRoot: Boolean = true, paths: string[] = ['/*'], ) { - const domain = new Domain(stack, 'Domain', { version: defaultVersion }); + const domain = new Domain(stack, 'Domain', { version: engineVersion }); const user = new iam.User(stack, 'user'); invocation(user, domain); @@ -1968,10 +2003,11 @@ function testGrant( function testMetric( invocation: (domain: Domain) => Metric, metricName: string, + engineVersion: EngineVersion, statistic: string = Statistic.SUM, period: Duration = Duration.minutes(5), ) { - const domain = new Domain(stack, 'Domain', { version: defaultVersion }); + const domain = new Domain(stack, 'Domain', { version: engineVersion }); const metric = invocation(domain); diff --git a/packages/@aws-cdk/cfnspec/CHANGELOG.md b/packages/@aws-cdk/cfnspec/CHANGELOG.md index 4ee9e6a4f21ea..0096664d36de4 100644 --- a/packages/@aws-cdk/cfnspec/CHANGELOG.md +++ b/packages/@aws-cdk/cfnspec/CHANGELOG.md @@ -1,3 +1,89 @@ +# CloudFormation Resource Specification v107.0.0 + +## New Resource Types + + +## Attribute Changes + +* AWS::ApiGateway::RestApi RestApiId (__added__) +* AWS::AuditManager::Assessment Delegations (__deleted__) +* AWS::DataSync::Task ErrorCode (__deleted__) +* AWS::DataSync::Task ErrorDetail (__deleted__) +* AWS::MediaPackage::Channel HlsIngest (__deleted__) +* AWS::MediaPackage::Channel HlsIngest.ingestEndpoints (__deleted__) +* AWS::RDS::DBCluster MasterUserSecret.SecretArn (__added__) +* AWS::RDS::DBInstance MasterUserSecret.SecretArn (__added__) + +## Property Changes + +* AWS::ApiGateway::RestApi Parameters.DuplicatesAllowed (__deleted__) +* AWS::AppSync::DataSource EventBridgeConfig (__added__) +* AWS::AuditManager::Assessment Delegations (__added__) +* AWS::DataSync::LocationFSxLustre FsxFilesystemArn.Required (__changed__) + * Old: true + * New: false +* AWS::DataSync::LocationFSxWindows FsxFilesystemArn.Required (__changed__) + * Old: true + * New: false +* AWS::DataSync::LocationFSxWindows Password.Required (__changed__) + * Old: true + * New: false +* AWS::DataSync::LocationNFS ServerHostname.Required (__changed__) + * Old: true + * New: false +* AWS::DataSync::LocationNFS Subdirectory.Required (__changed__) + * Old: true + * New: false +* AWS::DataSync::LocationObjectStorage BucketName.Required (__changed__) + * Old: true + * New: false +* AWS::DataSync::LocationObjectStorage ServerHostname.Required (__changed__) + * Old: true + * New: false +* AWS::DataSync::LocationSMB Password.Required (__changed__) + * Old: true + * New: false +* AWS::DataSync::LocationSMB ServerHostname.Required (__changed__) + * Old: true + * New: false +* AWS::DataSync::LocationSMB Subdirectory.Required (__changed__) + * Old: true + * New: false +* AWS::EC2::PlacementGroup PartitionCount (__added__) +* AWS::EC2::PlacementGroup Tags (__added__) +* AWS::IoT::JobTemplate JobExecutionsRetryConfig (__added__) +* AWS::Lambda::EventSourceMapping ScalingConfig (__added__) +* AWS::MediaPackage::Channel HlsIngest (__added__) +* AWS::RDS::DBCluster ManageMasterUserPassword (__added__) +* AWS::RDS::DBCluster MasterUserSecret (__added__) +* AWS::RDS::DBInstance ManageMasterUserPassword (__added__) +* AWS::RDS::DBInstance MasterUserSecret (__added__) + +## Property Type Changes + +* AWS::AppSync::DataSource.EventBridgeConfig (__added__) +* AWS::IoT::JobTemplate.JobExecutionsRetryConfig (__added__) +* AWS::IoT::JobTemplate.RetryCriteria (__added__) +* AWS::Lambda::EventSourceMapping.ScalingConfig (__added__) +* AWS::RDS::DBCluster.MasterUserSecret (__added__) +* AWS::RDS::DBInstance.MasterUserSecret (__added__) +* AWS::AppRunner::Service.CodeConfigurationValues RuntimeEnvironmentSecrets (__added__) +* AWS::AppRunner::Service.ImageConfiguration RuntimeEnvironmentSecrets (__added__) +* AWS::MediaPackage::Channel.IngestEndpoint Id.Required (__changed__) + * Old: false + * New: true +* AWS::MediaPackage::Channel.IngestEndpoint Password.Required (__changed__) + * Old: false + * New: true +* AWS::MediaPackage::Channel.IngestEndpoint Url.Required (__changed__) + * Old: false + * New: true +* AWS::MediaPackage::Channel.IngestEndpoint Username.Required (__changed__) + * Old: false + * New: true +* AWS::MediaPackage::PackagingConfiguration.DashPackage IncludeIframeOnlyStream (__added__) + + # CloudFormation Resource Specification v106.0.0 ## New Resource Types diff --git a/packages/@aws-cdk/cfnspec/cfn.version b/packages/@aws-cdk/cfnspec/cfn.version index 8cc2138c2964a..86cf4ece30e5b 100644 --- a/packages/@aws-cdk/cfnspec/cfn.version +++ b/packages/@aws-cdk/cfnspec/cfn.version @@ -1 +1 @@ -106.0.0 +107.0.0 diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ACMPCA.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ACMPCA.json index 1fdf405f795b6..2474f1e238237 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ACMPCA.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ACMPCA.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ACMPCA::Certificate.ApiPassthrough": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-acmpca-certificate-apipassthrough.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_APS.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_APS.json index b668af02c672a..5f54e830574ea 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_APS.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_APS.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::APS::Workspace.LoggingConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-aps-workspace-loggingconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AccessAnalyzer.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AccessAnalyzer.json index acb6ca326ef75..8a36feb2d78fe 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AccessAnalyzer.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AccessAnalyzer.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::AccessAnalyzer::Analyzer.ArchiveRule": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-accessanalyzer-analyzer-archiverule.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AmazonMQ.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AmazonMQ.json index 78e881e5eeccb..738b447423efb 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AmazonMQ.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AmazonMQ.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::AmazonMQ::Broker.ConfigurationId": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-amazonmq-broker-configurationid.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Amplify.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Amplify.json index 796ec064fdfb7..4ad3334b7f3aa 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Amplify.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Amplify.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Amplify::App.AutoBranchCreationConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-amplify-app-autobranchcreationconfig.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AmplifyUIBuilder.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AmplifyUIBuilder.json index 71af08989bd02..8ba1a4d652dd9 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AmplifyUIBuilder.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AmplifyUIBuilder.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::AmplifyUIBuilder::Component.ActionParameters": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-amplifyuibuilder-component-actionparameters.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApiGateway.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApiGateway.json index e6b939bfdd585..98843c6f1ece0 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApiGateway.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApiGateway.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ApiGateway::ApiKey.StageKey": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apigateway-apikey-stagekey.html", @@ -1329,6 +1329,9 @@ }, "AWS::ApiGateway::RestApi": { "Attributes": { + "RestApiId": { + "PrimitiveType": "String" + }, "RootResourceId": { "PrimitiveType": "String" } @@ -1411,7 +1414,6 @@ }, "Parameters": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-apigateway-restapi.html#cfn-apigateway-restapi-parameters", - "DuplicatesAllowed": false, "PrimitiveItemType": "String", "Required": false, "Type": "Map", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApiGatewayV2.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApiGatewayV2.json index c5ff77eeca388..dbc76c3c1ba4b 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApiGatewayV2.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApiGatewayV2.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ApiGatewayV2::Api.BodyS3Location": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apigatewayv2-api-bodys3location.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppConfig.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppConfig.json index f82dd87f2c31c..d654da8142251 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppConfig.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppConfig.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::AppConfig::Application.Tags": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appconfig-application-tags.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppFlow.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppFlow.json index 00b74ba7aa8c2..d0996d873b21e 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppFlow.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppFlow.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::AppFlow::Connector.ConnectorProvisioningConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appflow-connector-connectorprovisioningconfig.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppIntegrations.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppIntegrations.json index d4b60ed4032ef..6bea294230384 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppIntegrations.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppIntegrations.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::AppIntegrations::DataIntegration.ScheduleConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appintegrations-dataintegration-scheduleconfig.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppMesh.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppMesh.json index 7a7b1ea4582e7..2864f071849ac 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppMesh.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppMesh.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::AppMesh::GatewayRoute.GatewayRouteHostnameMatch": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appmesh-gatewayroute-gatewayroutehostnamematch.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppRunner.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppRunner.json index e948be7d1c0e0..a48164c813f47 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppRunner.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppRunner.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::AppRunner::ObservabilityConfiguration.TraceConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-observabilityconfiguration-traceconfiguration.html", @@ -67,6 +67,14 @@ "Required": true, "UpdateType": "Mutable" }, + "RuntimeEnvironmentSecrets": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-codeconfigurationvalues.html#cfn-apprunner-service-codeconfigurationvalues-runtimeenvironmentsecrets", + "DuplicatesAllowed": true, + "ItemType": "KeyValuePair", + "Required": false, + "Type": "List", + "UpdateType": "Mutable" + }, "RuntimeEnvironmentVariables": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-codeconfigurationvalues.html#cfn-apprunner-service-codeconfigurationvalues-runtimeenvironmentvariables", "DuplicatesAllowed": true, @@ -184,6 +192,14 @@ "Required": false, "UpdateType": "Mutable" }, + "RuntimeEnvironmentSecrets": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-imageconfiguration.html#cfn-apprunner-service-imageconfiguration-runtimeenvironmentsecrets", + "DuplicatesAllowed": true, + "ItemType": "KeyValuePair", + "Required": false, + "Type": "List", + "UpdateType": "Mutable" + }, "RuntimeEnvironmentVariables": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-imageconfiguration.html#cfn-apprunner-service-imageconfiguration-runtimeenvironmentvariables", "DuplicatesAllowed": true, diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppStream.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppStream.json index 6f69ef69082f3..aa59e6dd2e01b 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppStream.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppStream.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::AppStream::AppBlock.S3Location": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appstream-appblock-s3location.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppSync.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppSync.json index 5c95c3c5aa036..fae73fe566433 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppSync.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AppSync.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::AppSync::DataSource.AuthorizationConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appsync-datasource-authorizationconfig.html", @@ -110,6 +110,17 @@ } } }, + "AWS::AppSync::DataSource.EventBridgeConfig": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appsync-datasource-eventbridgeconfig.html", + "Properties": { + "EventBusArn": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appsync-datasource-eventbridgeconfig.html#cfn-appsync-datasource-eventbridgeconfig-eventbusarn", + "PrimitiveType": "String", + "Required": true, + "UpdateType": "Mutable" + } + } + }, "AWS::AppSync::DataSource.HttpConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-appsync-datasource-httpconfig.html", "Properties": { @@ -610,6 +621,12 @@ "Type": "ElasticsearchConfig", "UpdateType": "Mutable" }, + "EventBridgeConfig": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-appsync-datasource.html#cfn-appsync-datasource-eventbridgeconfig", + "Required": false, + "Type": "EventBridgeConfig", + "UpdateType": "Mutable" + }, "HttpConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-appsync-datasource.html#cfn-appsync-datasource-httpconfig", "Required": false, diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApplicationAutoScaling.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApplicationAutoScaling.json index 841a812bdf060..c9aa7ff17fa29 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApplicationAutoScaling.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApplicationAutoScaling.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ApplicationAutoScaling::ScalableTarget.ScalableTargetAction": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-applicationautoscaling-scalabletarget-scalabletargetaction.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApplicationInsights.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApplicationInsights.json index 6f6ad4b862593..ab3d279426040 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApplicationInsights.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ApplicationInsights.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ApplicationInsights::Application.Alarm": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-applicationinsights-application-alarm.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Athena.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Athena.json index 496e7a0544357..7813c5112b4ed 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Athena.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Athena.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Athena::WorkGroup.EncryptionConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-athena-workgroup-encryptionconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AuditManager.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AuditManager.json index edbde1b0e73c2..8ec5dfc3a9bbc 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AuditManager.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AuditManager.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::AuditManager::Assessment.AWSAccount": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-auditmanager-assessment-awsaccount.html", @@ -173,10 +173,6 @@ }, "CreationTime": { "PrimitiveType": "Double" - }, - "Delegations": { - "ItemType": "Delegation", - "Type": "List" } }, "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-auditmanager-assessment.html", @@ -193,6 +189,14 @@ "Type": "AWSAccount", "UpdateType": "Immutable" }, + "Delegations": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-auditmanager-assessment.html#cfn-auditmanager-assessment-delegations", + "DuplicatesAllowed": true, + "ItemType": "Delegation", + "Required": false, + "Type": "List", + "UpdateType": "Mutable" + }, "Description": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-auditmanager-assessment.html#cfn-auditmanager-assessment-description", "PrimitiveType": "String", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AutoScaling.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AutoScaling.json index e56b76b858692..679591864fc39 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AutoScaling.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AutoScaling.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::AutoScaling::AutoScalingGroup.AcceleratorCountRequest": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-autoscaling-autoscalinggroup-acceleratorcountrequest.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AutoScalingPlans.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AutoScalingPlans.json index 9ae9337d46c08..c7a12daa5eb3f 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AutoScalingPlans.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_AutoScalingPlans.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::AutoScalingPlans::ScalingPlan.ApplicationSource": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-autoscalingplans-scalingplan-applicationsource.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Backup.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Backup.json index 8be59b0400ac7..c8f622c2196e4 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Backup.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Backup.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Backup::BackupPlan.AdvancedBackupSettingResourceType": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-backup-backupplan-advancedbackupsettingresourcetype.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Batch.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Batch.json index 0b1fe11e079b6..189775b36b6f7 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Batch.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Batch.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Batch::ComputeEnvironment.ComputeResources": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_BillingConductor.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_BillingConductor.json index 5400cd5e355cd..402685f319d8f 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_BillingConductor.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_BillingConductor.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::BillingConductor::BillingGroup.AccountGrouping": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-billingconductor-billinggroup-accountgrouping.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Budgets.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Budgets.json index 5da5b19131897..f0760f36c20b2 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Budgets.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Budgets.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Budgets::Budget.AutoAdjustData": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-autoadjustdata.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CE.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CE.json index 8c52ded989ad5..0fc4ea2d08bf3 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CE.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CE.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::CE::AnomalyMonitor.ResourceTag": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ce-anomalymonitor-resourcetag.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CUR.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CUR.json index 96cb938a31a72..d1fb3803512d1 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CUR.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CUR.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::CUR::ReportDefinition": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Cassandra.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Cassandra.json index fcac0529b4026..daf14e2d77ca4 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Cassandra.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Cassandra.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Cassandra::Table.BillingMode": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-cassandra-table-billingmode.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CertificateManager.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CertificateManager.json index a5a1e92c2fc28..5cc52c10a208a 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CertificateManager.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CertificateManager.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::CertificateManager::Account.ExpiryEventsConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-certificatemanager-account-expiryeventsconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Chatbot.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Chatbot.json index 4843fbdf0541b..41c773de1d629 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Chatbot.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Chatbot.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::Chatbot::SlackChannelConfiguration": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Cloud9.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Cloud9.json index 816d72f04b1de..06cd158532ac2 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Cloud9.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Cloud9.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Cloud9::EnvironmentEC2.Repository": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-cloud9-environmentec2-repository.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudFormation.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudFormation.json index 9a4ec75f4429d..fd9597fb77fb4 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudFormation.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudFormation.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::CloudFormation::HookVersion.LoggingConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-cloudformation-hookversion-loggingconfig.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudFront.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudFront.json index 647d3f9ed7013..f81a0cda2106e 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudFront.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudFront.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::CloudFront::CachePolicy.CachePolicyConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-cloudfront-cachepolicy-cachepolicyconfig.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudTrail.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudTrail.json index 3303fd8452d7e..9d548ab3b4848 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudTrail.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudTrail.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::CloudTrail::EventDataStore.AdvancedEventSelector": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-cloudtrail-eventdatastore-advancedeventselector.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudWatch.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudWatch.json index 92b074178b590..a0537d846962b 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudWatch.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CloudWatch.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::CloudWatch::Alarm.Dimension": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-cw-dimension.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeArtifact.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeArtifact.json index 066ca59ddadab..6d090bcab726c 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeArtifact.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeArtifact.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::CodeArtifact::Domain": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeBuild.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeBuild.json index 95c5cb2e72bf1..278a15a4cc5ff 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeBuild.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeBuild.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::CodeBuild::Project.Artifacts": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codebuild-project-artifacts.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeCommit.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeCommit.json index f3b0cb8c2702d..fcb896314db7a 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeCommit.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeCommit.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::CodeCommit::Repository.Code": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codecommit-repository-code.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeDeploy.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeDeploy.json index c67ab192e357e..bcf4b967062d0 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeDeploy.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeDeploy.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::CodeDeploy::DeploymentConfig.MinimumHealthyHosts": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-minimumhealthyhosts.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeGuruProfiler.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeGuruProfiler.json index 83d7ccb369042..aea4997053c20 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeGuruProfiler.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeGuruProfiler.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::CodeGuruProfiler::ProfilingGroup.AgentPermissions": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codeguruprofiler-profilinggroup-agentpermissions.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeGuruReviewer.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeGuruReviewer.json index 0e9bd89d01bcc..072000a8a4741 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeGuruReviewer.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeGuruReviewer.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::CodeGuruReviewer::RepositoryAssociation": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodePipeline.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodePipeline.json index 99ea0419a7802..ae7e621d3f85e 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodePipeline.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodePipeline.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::CodePipeline::CustomActionType.ArtifactDetails": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codepipeline-customactiontype-artifactdetails.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeStar.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeStar.json index e84ac0b95fffc..6d319209979c8 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeStar.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeStar.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::CodeStar::GitHubRepository.Code": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codestar-githubrepository-code.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeStarConnections.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeStarConnections.json index 3ba6671c14a89..360c6288b850f 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeStarConnections.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeStarConnections.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::CodeStarConnections::Connection": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeStarNotifications.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeStarNotifications.json index 3dc4d9c7553f4..9776d317fc1e0 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeStarNotifications.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CodeStarNotifications.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::CodeStarNotifications::NotificationRule.Target": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codestarnotifications-notificationrule-target.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Cognito.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Cognito.json index 490fe48a774d9..a2cd9dcb90532 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Cognito.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Cognito.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Cognito::IdentityPool.CognitoIdentityProvider": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-cognito-identitypool-cognitoidentityprovider.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Config.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Config.json index 8a0e6d506f8b4..061db37e37e93 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Config.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Config.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Config::ConfigRule.CustomPolicyDetails": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-config-configrule-custompolicydetails.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Connect.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Connect.json index c62efbf0946ee..f9b79b2085986 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Connect.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Connect.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Connect::HoursOfOperation.HoursOfOperationConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-connect-hoursofoperation-hoursofoperationconfig.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ConnectCampaigns.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ConnectCampaigns.json index 6ffe3bd53d34f..f2c9f841e7f18 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ConnectCampaigns.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ConnectCampaigns.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ConnectCampaigns::Campaign.DialerConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-connectcampaigns-campaign-dialerconfig.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ControlTower.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ControlTower.json index dffc9f3cb6686..f0d827d7d8fa7 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ControlTower.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ControlTower.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::ControlTower::EnabledControl": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CustomerProfiles.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CustomerProfiles.json index d281b168d1df2..8f926207cc3d0 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CustomerProfiles.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_CustomerProfiles.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::CustomerProfiles::Integration.ConnectorOperator": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-customerprofiles-integration-connectoroperator.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DAX.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DAX.json index a7f75256a0e63..8061582f6af7b 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DAX.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DAX.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::DAX::Cluster.SSESpecification": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dax-cluster-ssespecification.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DLM.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DLM.json index 70ea224c09036..928f69d8eb0a3 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DLM.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DLM.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::DLM::LifecyclePolicy.Action": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dlm-lifecyclepolicy-action.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DMS.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DMS.json index cb7ef7571a795..4bba2f85c55c9 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DMS.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DMS.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::DMS::Endpoint.DocDbSettings": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dms-endpoint-docdbsettings.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DataBrew.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DataBrew.json index 918c60f314fbe..34d93dc4edd48 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DataBrew.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DataBrew.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::DataBrew::Dataset.CsvOptions": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-databrew-dataset-csvoptions.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DataPipeline.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DataPipeline.json index fccbc661676d5..eabda1f45ba93 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DataPipeline.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DataPipeline.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::DataPipeline::Pipeline.Field": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-datapipeline-pipeline-field.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DataSync.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DataSync.json index bf1726839acbb..3ce196223039b 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DataSync.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DataSync.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::DataSync::LocationEFS.Ec2Config": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-datasync-locationefs-ec2config.html", @@ -463,7 +463,7 @@ "FsxFilesystemArn": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-locationfsxlustre.html#cfn-datasync-locationfsxlustre-fsxfilesystemarn", "PrimitiveType": "String", - "Required": true, + "Required": false, "UpdateType": "Immutable" }, "SecurityGroupArns": { @@ -607,13 +607,13 @@ "FsxFilesystemArn": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-locationfsxwindows.html#cfn-datasync-locationfsxwindows-fsxfilesystemarn", "PrimitiveType": "String", - "Required": true, + "Required": false, "UpdateType": "Immutable" }, "Password": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-locationfsxwindows.html#cfn-datasync-locationfsxwindows-password", "PrimitiveType": "String", - "Required": true, + "Required": false, "UpdateType": "Immutable" }, "SecurityGroupArns": { @@ -769,13 +769,13 @@ "ServerHostname": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-locationnfs.html#cfn-datasync-locationnfs-serverhostname", "PrimitiveType": "String", - "Required": true, + "Required": false, "UpdateType": "Immutable" }, "Subdirectory": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-locationnfs.html#cfn-datasync-locationnfs-subdirectory", "PrimitiveType": "String", - "Required": true, + "Required": false, "UpdateType": "Mutable" }, "Tags": { @@ -816,7 +816,7 @@ "BucketName": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-locationobjectstorage.html#cfn-datasync-locationobjectstorage-bucketname", "PrimitiveType": "String", - "Required": true, + "Required": false, "UpdateType": "Immutable" }, "SecretKey": { @@ -828,7 +828,7 @@ "ServerHostname": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-locationobjectstorage.html#cfn-datasync-locationobjectstorage-serverhostname", "PrimitiveType": "String", - "Required": true, + "Required": false, "UpdateType": "Immutable" }, "ServerPort": { @@ -938,19 +938,19 @@ "Password": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-locationsmb.html#cfn-datasync-locationsmb-password", "PrimitiveType": "String", - "Required": true, + "Required": false, "UpdateType": "Mutable" }, "ServerHostname": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-locationsmb.html#cfn-datasync-locationsmb-serverhostname", "PrimitiveType": "String", - "Required": true, + "Required": false, "UpdateType": "Immutable" }, "Subdirectory": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-locationsmb.html#cfn-datasync-locationsmb-subdirectory", "PrimitiveType": "String", - "Required": true, + "Required": false, "UpdateType": "Mutable" }, "Tags": { @@ -975,12 +975,6 @@ "PrimitiveItemType": "String", "Type": "List" }, - "ErrorCode": { - "PrimitiveType": "String" - }, - "ErrorDetail": { - "PrimitiveType": "String" - }, "SourceNetworkInterfaceArns": { "PrimitiveItemType": "String", "Type": "List" diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Detective.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Detective.json index cfedaf25eaa73..b6eb8fbda1eeb 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Detective.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Detective.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::Detective::Graph": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DevOpsGuru.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DevOpsGuru.json index 6fd55a62211a7..c436a1744275c 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DevOpsGuru.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DevOpsGuru.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::DevOpsGuru::NotificationChannel.NotificationChannelConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsguru-notificationchannel-notificationchannelconfig.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DirectoryService.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DirectoryService.json index 768a0c589b457..0792db0ef7962 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DirectoryService.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DirectoryService.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::DirectoryService::MicrosoftAD.VpcSettings": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-directoryservice-microsoftad-vpcsettings.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DocDB.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DocDB.json index c9caf271aba17..601504b296ba3 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DocDB.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DocDB.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::DocDB::DBCluster": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DocDBElastic.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DocDBElastic.json index 8b5970fe22d36..5377a9f2ab6ed 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DocDBElastic.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DocDBElastic.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::DocDBElastic::Cluster": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DynamoDB.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DynamoDB.json index 4f3adc42c9d74..8aa57c99a75f0 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DynamoDB.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_DynamoDB.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::DynamoDB::GlobalTable.AttributeDefinition": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dynamodb-globaltable-attributedefinition.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EC2.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EC2.json index a69a843ef34f8..d1c1d95844c14 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EC2.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EC2.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::EC2::CapacityReservation.TagSpecification": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-capacityreservation-tagspecification.html", @@ -6799,6 +6799,12 @@ }, "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-placementgroup.html", "Properties": { + "PartitionCount": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-placementgroup.html#cfn-ec2-placementgroup-partitioncount", + "PrimitiveType": "Integer", + "Required": false, + "UpdateType": "Immutable" + }, "SpreadLevel": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-placementgroup.html#cfn-ec2-placementgroup-spreadlevel", "PrimitiveType": "String", @@ -6810,6 +6816,14 @@ "PrimitiveType": "String", "Required": false, "UpdateType": "Immutable" + }, + "Tags": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-placementgroup.html#cfn-ec2-placementgroup-tags", + "DuplicatesAllowed": false, + "ItemType": "Tag", + "Required": false, + "Type": "List", + "UpdateType": "Mutable" } } }, diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ECR.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ECR.json index 749daf0d1ea18..a9c49b8418d6a 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ECR.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ECR.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ECR::PublicRepository.RepositoryCatalogData": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ecr-publicrepository-repositorycatalogdata.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ECS.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ECS.json index 4cb5101960e7e..cab6fa29799f3 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ECS.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ECS.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ECS::CapacityProvider.AutoScalingGroupProvider": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ecs-capacityprovider-autoscalinggroupprovider.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EFS.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EFS.json index 073355f518c28..46a2b676abee4 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EFS.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EFS.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::EFS::AccessPoint.AccessPointTag": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-efs-accesspoint-accesspointtag.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EKS.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EKS.json index 11835cd4b266b..c196766b96860 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EKS.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EKS.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::EKS::Cluster.ClusterLogging": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-eks-cluster-clusterlogging.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EMR.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EMR.json index d8bf014243e9c..8f4d96cac5e46 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EMR.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EMR.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::EMR::Cluster.Application": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticmapreduce-cluster-application.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EMRContainers.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EMRContainers.json index 155a1a06e587a..1d80f0555fd16 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EMRContainers.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EMRContainers.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::EMRContainers::VirtualCluster.ContainerInfo": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-emrcontainers-virtualcluster-containerinfo.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EMRServerless.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EMRServerless.json index ba9504c3cc5db..a332d384042ae 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EMRServerless.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EMRServerless.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::EMRServerless::Application.AutoStartConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-emrserverless-application-autostartconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElastiCache.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElastiCache.json index efcd8b03beca5..bf998b9477616 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElastiCache.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElastiCache.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ElastiCache::CacheCluster.CloudWatchLogsDestinationDetails": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticache-cachecluster-cloudwatchlogsdestinationdetails.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElasticBeanstalk.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElasticBeanstalk.json index 5d41f4e35d1d9..af599333af5a8 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElasticBeanstalk.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElasticBeanstalk.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ElasticBeanstalk::Application.ApplicationResourceLifecycleConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticbeanstalk-application-applicationresourcelifecycleconfig.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElasticLoadBalancing.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElasticLoadBalancing.json index 123a3c0e2c404..99c52b6d8ce16 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElasticLoadBalancing.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElasticLoadBalancing.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ElasticLoadBalancing::LoadBalancer.AccessLoggingPolicy": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-elb-accessloggingpolicy.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElasticLoadBalancingV2.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElasticLoadBalancingV2.json index d517c26c64087..6e1929785d1d7 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElasticLoadBalancingV2.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ElasticLoadBalancingV2.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ElasticLoadBalancingV2::Listener.Action": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticloadbalancingv2-listener-action.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Elasticsearch.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Elasticsearch.json index b1e8a5e79d758..176a7e2173014 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Elasticsearch.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Elasticsearch.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Elasticsearch::Domain.AdvancedSecurityOptionsInput": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticsearch-domain-advancedsecurityoptionsinput.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EventSchemas.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EventSchemas.json index ecddf61fa488d..9aa543601b632 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EventSchemas.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_EventSchemas.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::EventSchemas::Discoverer.TagsEntry": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-eventschemas-discoverer-tagsentry.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Events.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Events.json index 7d4401fd3ea7b..98ef0e5d9b5fc 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Events.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Events.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Events::Connection.ApiKeyAuthParameters": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-events-connection-apikeyauthparameters.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Evidently.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Evidently.json index cdc5b42cbd092..f75d6ed8e7bf1 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Evidently.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Evidently.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Evidently::Experiment.MetricGoalObject": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-evidently-experiment-metricgoalobject.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FIS.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FIS.json index 21121d8802852..97558c1e7e750 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FIS.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FIS.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::FIS::ExperimentTemplate.CloudWatchLogsConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-fis-experimenttemplate-cloudwatchlogsconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FMS.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FMS.json index b523254f57adb..5707552a19290 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FMS.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FMS.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::FMS::Policy.IEMap": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-fms-policy-iemap.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FSx.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FSx.json index da21517b4cba0..56e1e5a1a2d06 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FSx.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FSx.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::FSx::DataRepositoryAssociation.AutoExportPolicy": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-fsx-datarepositoryassociation-autoexportpolicy.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FinSpace.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FinSpace.json index cf644710cce52..c62095975027b 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FinSpace.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FinSpace.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::FinSpace::Environment.FederationParameters": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-finspace-environment-federationparameters.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Forecast.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Forecast.json index 2932ce66680ef..a2a3b2bde7c19 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Forecast.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Forecast.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Forecast::Dataset.AttributesItems": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-forecast-dataset-attributesitems.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FraudDetector.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FraudDetector.json index b2927bed0dacd..c707a7c0f5eb2 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FraudDetector.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_FraudDetector.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::FraudDetector::Detector.EntityType": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-frauddetector-detector-entitytype.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GameLift.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GameLift.json index 474770e853ad7..1af755bb59bb1 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GameLift.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GameLift.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::GameLift::Alias.RoutingStrategy": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-alias-routingstrategy.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GlobalAccelerator.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GlobalAccelerator.json index 547c007909879..7952bcd99a4e3 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GlobalAccelerator.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GlobalAccelerator.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::GlobalAccelerator::EndpointGroup.EndpointConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-globalaccelerator-endpointgroup-endpointconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Glue.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Glue.json index e19179fad5c1a..31594a857dcc4 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Glue.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Glue.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Glue::Classifier.CsvClassifier": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-csvclassifier.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Grafana.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Grafana.json index 62997c39da0b1..953d0b37ae308 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Grafana.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Grafana.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Grafana::Workspace.AssertionAttributes": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-grafana-workspace-assertionattributes.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Greengrass.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Greengrass.json index e3ead9e0a438d..19a8f55f2e183 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Greengrass.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Greengrass.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Greengrass::ConnectorDefinition.Connector": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-greengrass-connectordefinition-connector.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GreengrassV2.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GreengrassV2.json index 1f70b75b42cef..26dd989d4f528 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GreengrassV2.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GreengrassV2.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::GreengrassV2::ComponentVersion.ComponentDependencyRequirement": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-greengrassv2-componentversion-componentdependencyrequirement.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GroundStation.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GroundStation.json index 72bfa94fb4df7..41fe029b70352 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GroundStation.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GroundStation.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::GroundStation::Config.AntennaDownlinkConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-groundstation-config-antennadownlinkconfig.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GuardDuty.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GuardDuty.json index d1339961b54a3..263659de526f3 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GuardDuty.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_GuardDuty.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::GuardDuty::Detector.CFNDataSourceConfigurations": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-guardduty-detector-cfndatasourceconfigurations.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_HealthLake.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_HealthLake.json index 3839bdba4a5a0..2982114cf2e4d 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_HealthLake.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_HealthLake.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::HealthLake::FHIRDatastore.CreatedAt": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-healthlake-fhirdatastore-createdat.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IAM.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IAM.json index 16bd173cc3879..86d46d7cf0d81 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IAM.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IAM.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::IAM::Group.Policy": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iam-policy.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IVS.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IVS.json index 8246220458e65..69eef6d1e0585 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IVS.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IVS.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::IVS::RecordingConfiguration.DestinationConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ivs-recordingconfiguration-destinationconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IdentityStore.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IdentityStore.json index edb5c47a40dc0..37ee3ed8ccea4 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IdentityStore.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IdentityStore.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::IdentityStore::GroupMembership.MemberId": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-identitystore-groupmembership-memberid.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ImageBuilder.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ImageBuilder.json index 840f915a1bd8e..a2a34340fe952 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ImageBuilder.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ImageBuilder.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ImageBuilder::ContainerRecipe.ComponentConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-imagebuilder-containerrecipe-componentconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Inspector.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Inspector.json index d19a69a5c55cf..b3091c1445657 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Inspector.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Inspector.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::Inspector::AssessmentTarget": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_InspectorV2.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_InspectorV2.json index 582e9e9eece9e..0c82110633147 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_InspectorV2.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_InspectorV2.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::InspectorV2::Filter.DateFilter": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-inspectorv2-filter-datefilter.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoT.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoT.json index 74d1dd302b059..b148c5126ea36 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoT.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoT.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::IoT::AccountAuditConfiguration.AuditCheckConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iot-accountauditconfiguration-auditcheckconfiguration.html", @@ -294,6 +294,19 @@ } } }, + "AWS::IoT::JobTemplate.JobExecutionsRetryConfig": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iot-jobtemplate-jobexecutionsretryconfig.html", + "Properties": { + "RetryCriteriaList": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iot-jobtemplate-jobexecutionsretryconfig.html#cfn-iot-jobtemplate-jobexecutionsretryconfig-retrycriterialist", + "DuplicatesAllowed": true, + "ItemType": "RetryCriteria", + "Required": false, + "Type": "List", + "UpdateType": "Mutable" + } + } + }, "AWS::IoT::JobTemplate.JobExecutionsRolloutConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iot-jobtemplate-jobexecutionsrolloutconfig.html", "Properties": { @@ -345,6 +358,23 @@ } } }, + "AWS::IoT::JobTemplate.RetryCriteria": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iot-jobtemplate-retrycriteria.html", + "Properties": { + "FailureType": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iot-jobtemplate-retrycriteria.html#cfn-iot-jobtemplate-retrycriteria-failuretype", + "PrimitiveType": "String", + "Required": false, + "UpdateType": "Mutable" + }, + "NumberOfRetries": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iot-jobtemplate-retrycriteria.html#cfn-iot-jobtemplate-retrycriteria-numberofretries", + "PrimitiveType": "Integer", + "Required": false, + "UpdateType": "Mutable" + } + } + }, "AWS::IoT::JobTemplate.TimeoutConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iot-jobtemplate-timeoutconfig.html", "Properties": { @@ -2312,6 +2342,12 @@ "Required": false, "UpdateType": "Immutable" }, + "JobExecutionsRetryConfig": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iot-jobtemplate.html#cfn-iot-jobtemplate-jobexecutionsretryconfig", + "Required": false, + "Type": "JobExecutionsRetryConfig", + "UpdateType": "Mutable" + }, "JobExecutionsRolloutConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iot-jobtemplate.html#cfn-iot-jobtemplate-jobexecutionsrolloutconfig", "Required": false, diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoT1Click.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoT1Click.json index 98dae796b859a..67f9f041484cb 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoT1Click.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoT1Click.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::IoT1Click::Project.DeviceTemplate": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iot1click-project-devicetemplate.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTAnalytics.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTAnalytics.json index 1c5fe09eef49a..d42576ca8bf3c 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTAnalytics.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTAnalytics.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::IoTAnalytics::Channel.ChannelStorage": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotanalytics-channel-channelstorage.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTCoreDeviceAdvisor.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTCoreDeviceAdvisor.json index eb3f0480aa5de..54317cb7fef0b 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTCoreDeviceAdvisor.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTCoreDeviceAdvisor.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::IoTCoreDeviceAdvisor::SuiteDefinition.DeviceUnderTest": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotcoredeviceadvisor-suitedefinition-deviceundertest.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTEvents.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTEvents.json index ae02439a5cb9a..a4f16e94eeaf9 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTEvents.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTEvents.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::IoTEvents::AlarmModel.AcknowledgeFlow": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotevents-alarmmodel-acknowledgeflow.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTFleetHub.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTFleetHub.json index 31e88b88f0645..b12f5ccec7312 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTFleetHub.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTFleetHub.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::IoTFleetHub::Application": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTFleetWise.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTFleetWise.json index 6ffe8e71f0fef..8db61776ca55a 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTFleetWise.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTFleetWise.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::IoTFleetWise::Campaign.CollectionScheme": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotfleetwise-campaign-collectionscheme.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTSiteWise.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTSiteWise.json index beacf455a2226..57ae5f81defb1 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTSiteWise.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTSiteWise.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::IoTSiteWise::AccessPolicy.AccessPolicyIdentity": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotsitewise-accesspolicy-accesspolicyidentity.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTThingsGraph.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTThingsGraph.json index 44fce883090fe..cc1d12fcd6b7a 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTThingsGraph.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTThingsGraph.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::IoTThingsGraph::FlowTemplate.DefinitionDocument": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotthingsgraph-flowtemplate-definitiondocument.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTTwinMaker.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTTwinMaker.json index 55237f35d375b..d869bc28a4878 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTTwinMaker.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTTwinMaker.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::IoTTwinMaker::ComponentType.DataConnector": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iottwinmaker-componenttype-dataconnector.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTWireless.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTWireless.json index e470fecb29da6..ab86ed6a33484 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTWireless.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_IoTWireless.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::IoTWireless::DeviceProfile.LoRaWANDeviceProfile": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotwireless-deviceprofile-lorawandeviceprofile.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KMS.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KMS.json index e576930380f46..95fbfadb9b8e4 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KMS.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KMS.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::KMS::Alias": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KafkaConnect.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KafkaConnect.json index e97973134f9df..c9580498269cf 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KafkaConnect.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KafkaConnect.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::KafkaConnect::Connector.ApacheKafkaCluster": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-kafkaconnect-connector-apachekafkacluster.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Kendra.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Kendra.json index 9789b6eafec68..94d789931f3a2 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Kendra.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Kendra.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Kendra::DataSource.AccessControlListConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-kendra-datasource-accesscontrollistconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Kinesis.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Kinesis.json index d52c98dc524fb..9150a534f9906 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Kinesis.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Kinesis.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Kinesis::Stream.StreamEncryption": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-kinesis-stream-streamencryption.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisAnalytics.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisAnalytics.json index 6bc4724ea1da5..975bda95caa47 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisAnalytics.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisAnalytics.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::KinesisAnalytics::Application.CSVMappingParameters": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-kinesisanalytics-application-csvmappingparameters.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisAnalyticsV2.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisAnalyticsV2.json index e67473a755247..422581141b4fd 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisAnalyticsV2.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisAnalyticsV2.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::KinesisAnalyticsV2::Application.ApplicationCodeConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-kinesisanalyticsv2-application-applicationcodeconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisFirehose.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisFirehose.json index 27348f041d0a7..5348aaaa06a47 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisFirehose.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisFirehose.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::KinesisFirehose::DeliveryStream.AmazonOpenSearchServerlessBufferingHints": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-kinesisfirehose-deliverystream-amazonopensearchserverlessbufferinghints.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisVideo.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisVideo.json index b8a71a4632cb0..59307c8b085a7 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisVideo.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_KinesisVideo.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::KinesisVideo::SignalingChannel": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LakeFormation.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LakeFormation.json index 67a158a417f48..20609f50bedb7 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LakeFormation.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LakeFormation.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::LakeFormation::DataCellsFilter.ColumnWildcard": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lakeformation-datacellsfilter-columnwildcard.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Lambda.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Lambda.json index 8ed2d0553c62c..d64250e7be4b2 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Lambda.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Lambda.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Lambda::Alias.AliasRoutingConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-alias-aliasroutingconfiguration.html", @@ -175,6 +175,17 @@ } } }, + "AWS::Lambda::EventSourceMapping.ScalingConfig": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-eventsourcemapping-scalingconfig.html", + "Properties": { + "MaximumConcurrency": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-eventsourcemapping-scalingconfig.html#cfn-lambda-eventsourcemapping-scalingconfig-maximumconcurrency", + "PrimitiveType": "Integer", + "Required": false, + "UpdateType": "Mutable" + } + } + }, "AWS::Lambda::EventSourceMapping.SelfManagedEventSource": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-eventsourcemapping-selfmanagedeventsource.html", "Properties": { @@ -675,6 +686,12 @@ "Type": "List", "UpdateType": "Mutable" }, + "ScalingConfig": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-eventsourcemapping.html#cfn-lambda-eventsourcemapping-scalingconfig", + "Required": false, + "Type": "ScalingConfig", + "UpdateType": "Mutable" + }, "SelfManagedEventSource": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-eventsourcemapping.html#cfn-lambda-eventsourcemapping-selfmanagedeventsource", "Required": false, diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Lex.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Lex.json index 1553d46b24c3a..23a3ebd69a067 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Lex.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Lex.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Lex::Bot.AdvancedRecognitionSetting": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lex-bot-advancedrecognitionsetting.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LicenseManager.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LicenseManager.json index 9c866cc7437db..8df04c0b3e913 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LicenseManager.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LicenseManager.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::LicenseManager::License.BorrowConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-licensemanager-license-borrowconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Lightsail.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Lightsail.json index 501c5663e683e..13cd10e463777 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Lightsail.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Lightsail.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Lightsail::Bucket.AccessRules": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-bucket-accessrules.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Location.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Location.json index eca9c842d7961..e2de91a675777 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Location.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Location.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Location::Map.MapConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-location-map-mapconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Logs.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Logs.json index 8af6944a94736..ee01f69f3456d 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Logs.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Logs.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Logs::MetricFilter.Dimension": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-logs-metricfilter-dimension.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LookoutEquipment.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LookoutEquipment.json index e9709c142f40e..71004c230c3ba 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LookoutEquipment.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LookoutEquipment.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::LookoutEquipment::InferenceScheduler.DataInputConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lookoutequipment-inferencescheduler-datainputconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LookoutMetrics.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LookoutMetrics.json index 599c911241fee..6350ee5f8b15b 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LookoutMetrics.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LookoutMetrics.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::LookoutMetrics::Alert.Action": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lookoutmetrics-alert-action.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LookoutVision.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LookoutVision.json index fb92288b9639c..d6c62a045a312 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LookoutVision.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_LookoutVision.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::LookoutVision::Project": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_M2.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_M2.json index 6e7c8d919b4f8..e58d9f2ddfd08 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_M2.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_M2.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::M2::Application.Definition": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-m2-application-definition.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MSK.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MSK.json index bb1737bda9959..6f130422d7c55 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MSK.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MSK.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::MSK::Cluster.BrokerLogs": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-msk-cluster-brokerlogs.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MWAA.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MWAA.json index 53ecf642f30c7..bc774ba82cf76 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MWAA.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MWAA.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::MWAA::Environment.LoggingConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mwaa-environment-loggingconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Macie.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Macie.json index f5e480989eda4..a26520d99495b 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Macie.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Macie.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Macie::AllowList.Criteria": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-macie-allowlist-criteria.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ManagedBlockchain.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ManagedBlockchain.json index b9ae365f57a44..fd60b22993dab 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ManagedBlockchain.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ManagedBlockchain.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ManagedBlockchain::Member.ApprovalThresholdPolicy": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-approvalthresholdpolicy.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaConnect.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaConnect.json index 8eae91dd8cc11..3667601f8f0ea 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaConnect.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaConnect.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::MediaConnect::Flow.Encryption": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mediaconnect-flow-encryption.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaConvert.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaConvert.json index dbe97f99c5e3a..507e3ce24e6bc 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaConvert.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaConvert.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::MediaConvert::JobTemplate.AccelerationSettings": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mediaconvert-jobtemplate-accelerationsettings.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaLive.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaLive.json index d7e04da3b8a91..796133fb6c213 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaLive.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaLive.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::MediaLive::Channel.AacSettings": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-medialive-channel-aacsettings.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaPackage.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaPackage.json index 2481f74fac3eb..fce25bea04c33 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaPackage.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaPackage.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::MediaPackage::Asset.EgressEndpoint": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mediapackage-asset-egressendpoint.html", @@ -37,25 +37,25 @@ "Id": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mediapackage-channel-ingestendpoint.html#cfn-mediapackage-channel-ingestendpoint-id", "PrimitiveType": "String", - "Required": false, + "Required": true, "UpdateType": "Mutable" }, "Password": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mediapackage-channel-ingestendpoint.html#cfn-mediapackage-channel-ingestendpoint-password", "PrimitiveType": "String", - "Required": false, + "Required": true, "UpdateType": "Mutable" }, "Url": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mediapackage-channel-ingestendpoint.html#cfn-mediapackage-channel-ingestendpoint-url", "PrimitiveType": "String", - "Required": false, + "Required": true, "UpdateType": "Mutable" }, "Username": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mediapackage-channel-ingestendpoint.html#cfn-mediapackage-channel-ingestendpoint-username", "PrimitiveType": "String", - "Required": false, + "Required": true, "UpdateType": "Mutable" } } @@ -697,6 +697,12 @@ "Required": false, "UpdateType": "Mutable" }, + "IncludeIframeOnlyStream": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mediapackage-packagingconfiguration-dashpackage.html#cfn-mediapackage-packagingconfiguration-dashpackage-includeiframeonlystream", + "PrimitiveType": "Boolean", + "Required": false, + "UpdateType": "Mutable" + }, "PeriodTriggers": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mediapackage-packagingconfiguration-dashpackage.html#cfn-mediapackage-packagingconfiguration-dashpackage-periodtriggers", "DuplicatesAllowed": true, @@ -1033,13 +1039,6 @@ "Attributes": { "Arn": { "PrimitiveType": "String" - }, - "HlsIngest": { - "Type": "HlsIngest" - }, - "HlsIngest.ingestEndpoints": { - "ItemType": "IngestEndpoint", - "Type": "List" } }, "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-mediapackage-channel.html", @@ -1056,6 +1055,12 @@ "Type": "LogConfiguration", "UpdateType": "Mutable" }, + "HlsIngest": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-mediapackage-channel.html#cfn-mediapackage-channel-hlsingest", + "Required": false, + "Type": "HlsIngest", + "UpdateType": "Mutable" + }, "Id": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-mediapackage-channel.html#cfn-mediapackage-channel-id", "PrimitiveType": "String", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaStore.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaStore.json index 4c27b98f36e68..8cebd7b21732f 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaStore.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaStore.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::MediaStore::Container.CorsRule": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mediastore-container-corsrule.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaTailor.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaTailor.json index 70dc28bf99710..6a55e1d5bf6d5 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaTailor.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MediaTailor.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::MediaTailor::PlaybackConfiguration.AdMarkerPassthrough": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mediatailor-playbackconfiguration-admarkerpassthrough.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MemoryDB.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MemoryDB.json index ce2940a5c8b54..06f7a1babd4dc 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MemoryDB.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_MemoryDB.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::MemoryDB::Cluster.Endpoint": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-memorydb-cluster-endpoint.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Neptune.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Neptune.json index e1fcd79086502..945c32c631879 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Neptune.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Neptune.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Neptune::DBCluster.DBClusterRole": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-neptune-dbcluster-dbclusterrole.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_NetworkFirewall.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_NetworkFirewall.json index 00212c6ba1c99..7fa60b655acdf 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_NetworkFirewall.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_NetworkFirewall.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::NetworkFirewall::Firewall.SubnetMapping": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-networkfirewall-firewall-subnetmapping.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_NetworkManager.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_NetworkManager.json index 8fb7ff1a79a12..b8f48f8392f64 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_NetworkManager.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_NetworkManager.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::NetworkManager::ConnectAttachment.ConnectAttachmentOptions": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-networkmanager-connectattachment-connectattachmentoptions.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_NimbleStudio.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_NimbleStudio.json index 4fb7c4b793b2a..5c4f8dd06ac35 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_NimbleStudio.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_NimbleStudio.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::NimbleStudio::LaunchProfile.StreamConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-nimblestudio-launchprofile-streamconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Oam.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Oam.json index 281db56b93d6c..99e14b7e2bce3 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Oam.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Oam.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::Oam::Link": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpenSearchServerless.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpenSearchServerless.json index d3d6528877f67..b9af56935e27c 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpenSearchServerless.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpenSearchServerless.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::OpenSearchServerless::SecurityConfig.SamlConfigOptions": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-opensearchserverless-securityconfig-samlconfigoptions.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpenSearchService.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpenSearchService.json index c0ae53ff2b3b4..73f19a924d1d4 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpenSearchService.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpenSearchService.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::OpenSearchService::Domain.AdvancedSecurityOptionsInput": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-opensearchservice-domain-advancedsecurityoptionsinput.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpsWorks.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpsWorks.json index ed5e8ccb3929a..8d1e0c1d6f970 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpsWorks.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpsWorks.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::OpsWorks::App.DataSource": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-opsworks-app-datasource.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpsWorksCM.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpsWorksCM.json index 023c47b6bc0ff..8c55fbe1fab4e 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpsWorksCM.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_OpsWorksCM.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::OpsWorksCM::Server.EngineAttribute": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-opsworkscm-server-engineattribute.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Organizations.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Organizations.json index 04d961c8871b9..83b35bf920f36 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Organizations.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Organizations.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::Organizations::Account": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Panorama.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Panorama.json index 1e9a59d43a737..1564233a0ba0e 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Panorama.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Panorama.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Panorama::ApplicationInstance.ManifestOverridesPayload": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-panorama-applicationinstance-manifestoverridespayload.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Personalize.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Personalize.json index a8e0cf6720d70..65d84bd4a11c0 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Personalize.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Personalize.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Personalize::Dataset.DataSource": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-personalize-dataset-datasource.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Pinpoint.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Pinpoint.json index 8cd5adb3c069b..a31b2e832b7aa 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Pinpoint.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Pinpoint.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Pinpoint::ApplicationSettings.CampaignHook": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-pinpoint-applicationsettings-campaignhook.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_PinpointEmail.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_PinpointEmail.json index a968dd97710f9..451dc8713338c 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_PinpointEmail.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_PinpointEmail.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::PinpointEmail::ConfigurationSet.DeliveryOptions": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-pinpointemail-configurationset-deliveryoptions.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Pipes.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Pipes.json index f1f2f3698cabc..8afb59ad0c6b3 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Pipes.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Pipes.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Pipes::Pipe.AwsVpcConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-pipes-pipe-awsvpcconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_QLDB.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_QLDB.json index 9244428af213d..1584ce4511112 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_QLDB.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_QLDB.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::QLDB::Stream.KinesisConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-qldb-stream-kinesisconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_QuickSight.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_QuickSight.json index f33294a293f62..3a12d9b95f357 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_QuickSight.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_QuickSight.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::QuickSight::Analysis.AnalysisError": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-analysis-analysiserror.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RAM.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RAM.json index 6c700c4534f23..289a0d7f86712 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RAM.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RAM.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::RAM::ResourceShare": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RDS.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RDS.json index ff23618bec497..25eb39e27a2ad 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RDS.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RDS.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::RDS::DBCluster.DBClusterRole": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rds-dbcluster-dbclusterrole.html", @@ -35,6 +35,23 @@ } } }, + "AWS::RDS::DBCluster.MasterUserSecret": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rds-dbcluster-masterusersecret.html", + "Properties": { + "KmsKeyId": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rds-dbcluster-masterusersecret.html#cfn-rds-dbcluster-masterusersecret-kmskeyid", + "PrimitiveType": "String", + "Required": false, + "UpdateType": "Mutable" + }, + "SecretArn": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rds-dbcluster-masterusersecret.html#cfn-rds-dbcluster-masterusersecret-secretarn", + "PrimitiveType": "String", + "Required": false, + "UpdateType": "Mutable" + } + } + }, "AWS::RDS::DBCluster.ReadEndpoint": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rds-dbcluster-readendpoint.html", "Properties": { @@ -144,6 +161,23 @@ } } }, + "AWS::RDS::DBInstance.MasterUserSecret": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rds-dbinstance-masterusersecret.html", + "Properties": { + "KmsKeyId": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rds-dbinstance-masterusersecret.html#cfn-rds-dbinstance-masterusersecret-kmskeyid", + "PrimitiveType": "String", + "Required": false, + "UpdateType": "Mutable" + }, + "SecretArn": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rds-dbinstance-masterusersecret.html#cfn-rds-dbinstance-masterusersecret-secretarn", + "PrimitiveType": "String", + "Required": false, + "UpdateType": "Mutable" + } + } + }, "AWS::RDS::DBInstance.ProcessorFeature": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rds-dbinstance-processorfeature.html", "Properties": { @@ -385,6 +419,9 @@ "Endpoint.Port": { "PrimitiveType": "String" }, + "MasterUserSecret.SecretArn": { + "PrimitiveType": "String" + }, "ReadEndpoint.Address": { "PrimitiveType": "String" } @@ -553,12 +590,24 @@ "Required": false, "UpdateType": "Immutable" }, + "ManageMasterUserPassword": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-dbcluster.html#cfn-rds-dbcluster-managemasteruserpassword", + "PrimitiveType": "Boolean", + "Required": false, + "UpdateType": "Mutable" + }, "MasterUserPassword": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-dbcluster.html#cfn-rds-dbcluster-masteruserpassword", "PrimitiveType": "String", "Required": false, "UpdateType": "Mutable" }, + "MasterUserSecret": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-dbcluster.html#cfn-rds-dbcluster-masterusersecret", + "Required": false, + "Type": "MasterUserSecret", + "UpdateType": "Mutable" + }, "MasterUsername": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-dbcluster.html#cfn-rds-dbcluster-masterusername", "PrimitiveType": "String", @@ -759,6 +808,9 @@ }, "Endpoint.Port": { "PrimitiveType": "String" + }, + "MasterUserSecret.SecretArn": { + "PrimitiveType": "String" } }, "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-dbinstance.html", @@ -961,12 +1013,24 @@ "Required": false, "UpdateType": "Mutable" }, + "ManageMasterUserPassword": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-dbinstance.html#cfn-rds-dbinstance-managemasteruserpassword", + "PrimitiveType": "Boolean", + "Required": false, + "UpdateType": "Mutable" + }, "MasterUserPassword": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-dbinstance.html#cfn-rds-dbinstance-masteruserpassword", "PrimitiveType": "String", "Required": false, "UpdateType": "Mutable" }, + "MasterUserSecret": { + "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-dbinstance.html#cfn-rds-dbinstance-masterusersecret", + "Required": false, + "Type": "MasterUserSecret", + "UpdateType": "Mutable" + }, "MasterUsername": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-dbinstance.html#cfn-rds-dbinstance-masterusername", "PrimitiveType": "String", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RUM.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RUM.json index bff358647e3df..ed3bb3301ed34 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RUM.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RUM.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::RUM::AppMonitor.AppMonitorConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rum-appmonitor-appmonitorconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Redshift.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Redshift.json index fd7a82454ef9f..028e40a5342d5 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Redshift.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Redshift.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Redshift::Cluster.Endpoint": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-redshift-cluster-endpoint.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RedshiftServerless.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RedshiftServerless.json index e9e49570f96cb..732a495d03211 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RedshiftServerless.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RedshiftServerless.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::RedshiftServerless::Namespace.Namespace": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-redshiftserverless-namespace-namespace.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RefactorSpaces.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RefactorSpaces.json index 3ca6011356d5a..b515322a9202e 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RefactorSpaces.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RefactorSpaces.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::RefactorSpaces::Application.ApiGatewayProxyInput": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-refactorspaces-application-apigatewayproxyinput.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Rekognition.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Rekognition.json index 575c06ae58b95..68631605954b2 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Rekognition.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Rekognition.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Rekognition::StreamProcessor.BoundingBox": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rekognition-streamprocessor-boundingbox.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ResilienceHub.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ResilienceHub.json index 1f9bf7b9c017f..00c665e558c30 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ResilienceHub.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ResilienceHub.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ResilienceHub::App.PhysicalResourceId": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-resiliencehub-app-physicalresourceid.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ResourceExplorer2.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ResourceExplorer2.json index c547c2cf09a40..06ba0bb28c46f 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ResourceExplorer2.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ResourceExplorer2.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ResourceExplorer2::View.Filters": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-resourceexplorer2-view-filters.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ResourceGroups.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ResourceGroups.json index c457051e96f33..c5a4aefa4830a 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ResourceGroups.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ResourceGroups.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ResourceGroups::Group.ConfigurationItem": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-resourcegroups-group-configurationitem.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RoboMaker.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RoboMaker.json index c2a7b91ba3f83..3d8d75aba7ef9 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RoboMaker.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RoboMaker.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::RoboMaker::RobotApplication.RobotSoftwareSuite": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-robomaker-robotapplication-robotsoftwaresuite.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RolesAnywhere.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RolesAnywhere.json index 3592da00ef5d1..bc6ba4c2e29fe 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RolesAnywhere.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_RolesAnywhere.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::RolesAnywhere::TrustAnchor.Source": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rolesanywhere-trustanchor-source.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53.json index 869d1eaf8e4d4..50d7979db4734 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Route53::CidrCollection.Location": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53-cidrcollection-location.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53RecoveryControl.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53RecoveryControl.json index 0f94d70660ddd..8e695317d1733 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53RecoveryControl.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53RecoveryControl.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Route53RecoveryControl::Cluster.ClusterEndpoint": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53recoverycontrol-cluster-clusterendpoint.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53RecoveryReadiness.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53RecoveryReadiness.json index d9c77609a9cd0..a1d0ddc7b5594 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53RecoveryReadiness.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53RecoveryReadiness.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Route53RecoveryReadiness::ResourceSet.DNSTargetResource": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53recoveryreadiness-resourceset-dnstargetresource.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53Resolver.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53Resolver.json index 34167ffeb4b20..140a635edd409 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53Resolver.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Route53Resolver.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Route53Resolver::FirewallRuleGroup.FirewallRule": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53resolver-firewallrulegroup-firewallrule.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_S3.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_S3.json index d8a7b5ed81c04..7eb5d0cf37eb8 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_S3.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_S3.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::S3::AccessPoint.PolicyStatus": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-accesspoint-policystatus.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_S3ObjectLambda.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_S3ObjectLambda.json index 2c35a5bc518b9..52b2f95cd2a45 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_S3ObjectLambda.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_S3ObjectLambda.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::S3ObjectLambda::AccessPoint.AwsLambda": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3objectlambda-accesspoint-awslambda.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_S3Outposts.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_S3Outposts.json index e14bb91b9703d..c0c92dd68ab8c 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_S3Outposts.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_S3Outposts.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::S3Outposts::AccessPoint.VpcConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3outposts-accesspoint-vpcconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SDB.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SDB.json index 521331a6ee33e..e2d8ae4ee7b1f 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SDB.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SDB.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::SDB::Domain": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SES.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SES.json index 1c40bfed761c2..0c87b5aebe164 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SES.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SES.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::SES::ConfigurationSet.DashboardOptions": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ses-configurationset-dashboardoptions.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SNS.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SNS.json index 7c40bd5721426..d08b041e94caa 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SNS.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SNS.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::SNS::Topic.Subscription": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-sns-topic-subscription.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SQS.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SQS.json index 49b0c550144b2..500bf5ba4591e 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SQS.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SQS.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::SQS::Queue": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSM.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSM.json index b0902a49f613e..e78500856a687 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSM.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSM.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::SSM::Association.InstanceAssociationOutputLocation": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-association-instanceassociationoutputlocation.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSMContacts.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSMContacts.json index e2adf35c699f4..206f8f4d96bd2 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSMContacts.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSMContacts.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::SSMContacts::Contact.ChannelTargetInfo": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssmcontacts-contact-channeltargetinfo.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSMIncidents.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSMIncidents.json index 38a67273ccd55..581445630df6b 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSMIncidents.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSMIncidents.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::SSMIncidents::ReplicationSet.RegionConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssmincidents-replicationset-regionconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSO.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSO.json index c3dfed55179ab..9420a93c47d32 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSO.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SSO.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::SSO::InstanceAccessControlAttributeConfiguration.AccessControlAttribute": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-sso-instanceaccesscontrolattributeconfiguration-accesscontrolattribute.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SageMaker.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SageMaker.json index db3c464a9543c..e6bfbbecf2f28 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SageMaker.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SageMaker.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::SageMaker::App.ResourceSpec": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-sagemaker-app-resourcespec.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Scheduler.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Scheduler.json index f625fa5291a70..f846c9a9194f2 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Scheduler.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Scheduler.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Scheduler::Schedule.AwsVpcConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-scheduler-schedule-awsvpcconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SecretsManager.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SecretsManager.json index 6d2b169dab091..7b910ec7575df 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SecretsManager.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SecretsManager.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::SecretsManager::RotationSchedule.HostedRotationLambda": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-secretsmanager-rotationschedule-hostedrotationlambda.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SecurityHub.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SecurityHub.json index a9aeac8115c44..225841f504bb2 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SecurityHub.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SecurityHub.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::SecurityHub::Hub": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ServiceCatalog.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ServiceCatalog.json index f434377a43776..7fdcc6afd3af5 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ServiceCatalog.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ServiceCatalog.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ServiceCatalog::CloudFormationProduct.ProvisioningArtifactProperties": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-servicecatalog-cloudformationproduct-provisioningartifactproperties.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ServiceCatalogAppRegistry.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ServiceCatalogAppRegistry.json index 45c3ce562f522..d418cae63a717 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ServiceCatalogAppRegistry.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ServiceCatalogAppRegistry.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::ServiceCatalogAppRegistry::Application": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ServiceDiscovery.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ServiceDiscovery.json index 03e2e04bb9aa3..e4355e2cecc35 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ServiceDiscovery.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_ServiceDiscovery.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::ServiceDiscovery::PrivateDnsNamespace.PrivateDnsPropertiesMutable": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-servicediscovery-privatednsnamespace-privatednspropertiesmutable.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Signer.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Signer.json index 7393151da0852..6f706f895cb3f 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Signer.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Signer.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Signer::SigningProfile.SignatureValidityPeriod": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-signer-signingprofile-signaturevalidityperiod.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_StepFunctions.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_StepFunctions.json index 61f1a5c802031..7059b67420b53 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_StepFunctions.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_StepFunctions.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::StepFunctions::Activity.TagsEntry": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-stepfunctions-activity-tagsentry.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SupportApp.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SupportApp.json index 381792c85ea1f..d685930682492 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SupportApp.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_SupportApp.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": {}, "ResourceTypes": { "AWS::SupportApp::AccountAlias": { diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Synthetics.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Synthetics.json index 7bf5c8abcbb91..b04d2fc34893e 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Synthetics.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Synthetics.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Synthetics::Canary.ArtifactConfig": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-synthetics-canary-artifactconfig.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Timestream.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Timestream.json index 5637503f86681..cefb779eb0281 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Timestream.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Timestream.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Timestream::ScheduledQuery.DimensionMapping": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-timestream-scheduledquery-dimensionmapping.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Transfer.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Transfer.json index 555c06d701564..a186095583935 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Transfer.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Transfer.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Transfer::Connector.As2Config": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-transfer-connector-as2config.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_VoiceID.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_VoiceID.json index cad7c3e4a5fb3..e306e9b33ed87 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_VoiceID.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_VoiceID.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::VoiceID::Domain.ServerSideEncryptionConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-voiceid-domain-serversideencryptionconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WAF.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WAF.json index ddcafcb6368d2..3243af1558a4b 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WAF.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WAF.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::WAF::ByteMatchSet.ByteMatchTuple": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-waf-bytematchset-bytematchtuples.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WAFRegional.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WAFRegional.json index ab848de185240..d882a90765294 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WAFRegional.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WAFRegional.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::WAFRegional::ByteMatchSet.ByteMatchTuple": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-wafregional-bytematchset-bytematchtuple.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WAFv2.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WAFv2.json index 4f84b1b414d48..595461e8984a7 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WAFv2.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WAFv2.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::WAFv2::LoggingConfiguration.ActionCondition": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-wafv2-loggingconfiguration-actioncondition.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Wisdom.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Wisdom.json index e21579f130aec..41b8b98cd8ab6 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Wisdom.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Wisdom.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::Wisdom::Assistant.ServerSideEncryptionConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-wisdom-assistant-serversideencryptionconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WorkSpaces.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WorkSpaces.json index ac415ab54b88f..ceb2f3e83bae5 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WorkSpaces.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_WorkSpaces.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::WorkSpaces::ConnectionAlias.ConnectionAliasAssociation": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-workspaces-connectionalias-connectionaliasassociation.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_XRay.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_XRay.json index b34b8a74cd7a8..6f3f25f74f4c0 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_XRay.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_XRay.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "AWS::XRay::Group.InsightsConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-xray-group-insightsconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_Alexa_ASK.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_Alexa_ASK.json index cfe6bdddbfc89..d967ee9dc0292 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_Alexa_ASK.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_Alexa_ASK.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "Alexa::ASK::Skill.AuthenticationConfiguration": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ask-skill-authenticationconfiguration.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_Tag.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_Tag.json index 75db42cd96a73..53dd0b161efdf 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_Tag.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_Tag.json @@ -1,5 +1,5 @@ { - "$version": "106.0.0", + "$version": "107.0.0", "PropertyTypes": { "Tag": { "Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-resource-tags.html", diff --git a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/001_Version.json b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/001_Version.json index 7af9c5f68860f..5297fe34ac1e9 100644 --- a/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/001_Version.json +++ b/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/001_Version.json @@ -1,3 +1,3 @@ { - "ResourceSpecificationVersion": "106.0.0" + "ResourceSpecificationVersion": "107.0.0" } diff --git a/packages/@aws-cdk/core/lib/app.ts b/packages/@aws-cdk/core/lib/app.ts index ea72e4be2ca6a..1ae43828c8c3e 100644 --- a/packages/@aws-cdk/core/lib/app.ts +++ b/packages/@aws-cdk/core/lib/app.ts @@ -1,7 +1,9 @@ import * as cxapi from '@aws-cdk/cx-api'; import { Construct } from 'constructs'; import * as fs from 'fs-extra'; +import { PRIVATE_CONTEXT_DEFAULT_STACK_SYNTHESIZER } from './private/private-context'; import { addCustomSynthesis, ICustomSynthesis } from './private/synthesis'; +import { IReusableStackSynthesizer } from './stack-synthesizers'; import { Stage } from './stage'; const APP_SYMBOL = Symbol.for('@aws-cdk/core.App'); @@ -105,6 +107,17 @@ export interface AppProps { * @default true */ readonly treeMetadata?: boolean; + + /** + * The stack synthesizer to use by default for all Stacks in the App + * + * The Stack Synthesizer controls aspects of synthesis and deployment, + * like how assets are referenced and what IAM roles to use. For more + * information, see the README of the main CDK package. + * + * @default - A `DefaultStackSynthesizer` with default settings + */ + readonly defaultStackSynthesizer?: IReusableStackSynthesizer; } /** @@ -156,6 +169,10 @@ export class App extends Stage { this.node.setContext(cxapi.DISABLE_METADATA_STACK_TRACE, true); } + if (props.defaultStackSynthesizer) { + this.node.setContext(PRIVATE_CONTEXT_DEFAULT_STACK_SYNTHESIZER, props.defaultStackSynthesizer); + } + const analyticsReporting = props.analyticsReporting ?? props.runtimeInfo; if (analyticsReporting !== undefined) { diff --git a/packages/@aws-cdk/core/lib/environment.ts b/packages/@aws-cdk/core/lib/environment.ts index a43ec37f3472c..794aeeaaad200 100644 --- a/packages/@aws-cdk/core/lib/environment.ts +++ b/packages/@aws-cdk/core/lib/environment.ts @@ -9,7 +9,7 @@ export interface Environment { * indicates that account ID will only be determined during deployment (it * will resolve to the CloudFormation intrinsic `{"Ref":"AWS::AccountId"}`). * Note that certain features, such as cross-stack references and - * environmental context providers require concerete region information and + * environmental context providers require concrete region information and * will cause this stack to emit synthesis errors. * * @default Aws.ACCOUNT_ID which means that the stack will be account-agnostic. diff --git a/packages/@aws-cdk/core/lib/private/private-context.ts b/packages/@aws-cdk/core/lib/private/private-context.ts new file mode 100644 index 0000000000000..33af8a5561ea2 --- /dev/null +++ b/packages/@aws-cdk/core/lib/private/private-context.ts @@ -0,0 +1,10 @@ +/** + * Some construct-tree wide config we pass via context, because it's convenient. + * + * Users shouldn't touch these, and to make sure they don't we make sure the + * context keys have an unguessable prefix that is different on each execution. + */ + +const PREFIX = `aws-cdk-private:${Math.random()}:`; + +export const PRIVATE_CONTEXT_DEFAULT_STACK_SYNTHESIZER = `${PREFIX}core/defaultStackSynthesizer`; \ No newline at end of file diff --git a/packages/@aws-cdk/core/lib/stack-synthesizers/bootstrapless-synthesizer.ts b/packages/@aws-cdk/core/lib/stack-synthesizers/bootstrapless-synthesizer.ts index 2f25e0a635228..c48f476fc0d22 100644 --- a/packages/@aws-cdk/core/lib/stack-synthesizers/bootstrapless-synthesizer.ts +++ b/packages/@aws-cdk/core/lib/stack-synthesizers/bootstrapless-synthesizer.ts @@ -33,6 +33,9 @@ export interface BootstraplessSynthesizerProps { * However, it will not assume asset buckets or repositories have been created, * and therefore does not support assets. * + * The name is poorly chosen -- it does still require bootstrapping, it just + * does not support assets. + * * Used by the CodePipeline construct for the support stacks needed for * cross-region replication S3 buckets. App builders do not need to use this * synthesizer directly. diff --git a/packages/@aws-cdk/core/lib/stack-synthesizers/cli-credentials-synthesizer.ts b/packages/@aws-cdk/core/lib/stack-synthesizers/cli-credentials-synthesizer.ts index 66857c02b0b08..10dd38ea67a23 100644 --- a/packages/@aws-cdk/core/lib/stack-synthesizers/cli-credentials-synthesizer.ts +++ b/packages/@aws-cdk/core/lib/stack-synthesizers/cli-credentials-synthesizer.ts @@ -6,7 +6,7 @@ import { assertBound, StringSpecializer } from './_shared'; import { AssetManifestBuilder } from './asset-manifest-builder'; import { BOOTSTRAP_QUALIFIER_CONTEXT, DefaultStackSynthesizer } from './default-synthesizer'; import { StackSynthesizer } from './stack-synthesizer'; -import { ISynthesisSession } from './types'; +import { ISynthesisSession, IReusableStackSynthesizer, IBoundStackSynthesizer } from './types'; /** * Properties for the CliCredentialsStackSynthesizer @@ -86,7 +86,7 @@ export interface CliCredentialsStackSynthesizerProps { * of the Bootstrap Stack V2 (also known as "modern bootstrap stack"). You can override * the default names using the synthesizer's construction properties. */ -export class CliCredentialsStackSynthesizer extends StackSynthesizer { +export class CliCredentialsStackSynthesizer extends StackSynthesizer implements IReusableStackSynthesizer, IBoundStackSynthesizer { private qualifier?: string; private bucketName?: string; private repositoryName?: string; @@ -140,6 +140,18 @@ export class CliCredentialsStackSynthesizer extends StackSynthesizer { /* eslint-enable max-len */ } + /** + * Produce a bound Stack Synthesizer for the given stack. + * + * This method may be called more than once on the same object. + */ + public reusableBind(stack: Stack): IBoundStackSynthesizer { + // Create a copy of the current object and bind that + const copy = Object.create(this); + copy.bind(stack); + return copy; + } + public addFileAsset(asset: FileAssetSource): FileAssetLocation { assertBound(this.bucketName); diff --git a/packages/@aws-cdk/core/lib/stack-synthesizers/default-synthesizer.ts b/packages/@aws-cdk/core/lib/stack-synthesizers/default-synthesizer.ts index 6d5aa60a3517f..8b44f970fe8c5 100644 --- a/packages/@aws-cdk/core/lib/stack-synthesizers/default-synthesizer.ts +++ b/packages/@aws-cdk/core/lib/stack-synthesizers/default-synthesizer.ts @@ -5,7 +5,7 @@ import { Token } from '../token'; import { assertBound, StringSpecializer } from './_shared'; import { AssetManifestBuilder } from './asset-manifest-builder'; import { StackSynthesizer } from './stack-synthesizer'; -import { ISynthesisSession } from './types'; +import { ISynthesisSession, IReusableStackSynthesizer, IBoundStackSynthesizer } from './types'; export const BOOTSTRAP_QUALIFIER_CONTEXT = '@aws-cdk/core:bootstrapQualifier'; @@ -227,7 +227,7 @@ export interface DefaultStackSynthesizerProps { * check to the template, to make sure the bootstrap stack is recent enough * to support all features expected by this synthesizer. */ -export class DefaultStackSynthesizer extends StackSynthesizer { +export class DefaultStackSynthesizer extends StackSynthesizer implements IReusableStackSynthesizer, IBoundStackSynthesizer { /** * Default ARN qualifier */ @@ -324,6 +324,18 @@ export class DefaultStackSynthesizer extends StackSynthesizer { } } + /** + * Produce a bound Stack Synthesizer for the given stack. + * + * This method may be called more than once on the same object. + */ + public reusableBind(stack: Stack): IBoundStackSynthesizer { + // Create a copy of the current object and bind that + const copy = Object.create(this); + copy.bind(stack); + return copy; + } + /** * The qualifier used to bootstrap this stack */ diff --git a/packages/@aws-cdk/core/lib/stack-synthesizers/legacy.ts b/packages/@aws-cdk/core/lib/stack-synthesizers/legacy.ts index 3b2cc5d1a4f45..23d6af8ee5522 100644 --- a/packages/@aws-cdk/core/lib/stack-synthesizers/legacy.ts +++ b/packages/@aws-cdk/core/lib/stack-synthesizers/legacy.ts @@ -4,9 +4,10 @@ import { Construct } from 'constructs'; import { DockerImageAssetLocation, DockerImageAssetSource, FileAssetLocation, FileAssetSource } from '../assets'; import { Fn } from '../cfn-fn'; import { FileAssetParameters } from '../private/asset-parameters'; +import { Stack } from '../stack'; import { assertBound } from './_shared'; import { StackSynthesizer } from './stack-synthesizer'; -import { ISynthesisSession } from './types'; +import { ISynthesisSession, IReusableStackSynthesizer, IBoundStackSynthesizer } from './types'; /** * The well-known name for the docker image asset ECR repository. All docker @@ -44,7 +45,7 @@ const ASSETS_ECR_REPOSITORY_NAME_OVERRIDE_CONTEXT_KEY = 'assets-ecr-repository-n * This is the only StackSynthesizer that supports customizing asset behavior * by overriding `Stack.addFileAsset()` and `Stack.addDockerImageAsset()`. */ -export class LegacyStackSynthesizer extends StackSynthesizer { +export class LegacyStackSynthesizer extends StackSynthesizer implements IReusableStackSynthesizer, IBoundStackSynthesizer { private cycle = false; /** @@ -109,6 +110,18 @@ export class LegacyStackSynthesizer extends StackSynthesizer { this.emitArtifact(session); } + /** + * Produce a bound Stack Synthesizer for the given stack. + * + * This method may be called more than once on the same object. + */ + public reusableBind(stack: Stack): IBoundStackSynthesizer { + // Create a copy of the current object and bind that + const copy = Object.create(this); + copy.bind(stack); + return copy; + } + private doAddDockerImageAsset(asset: DockerImageAssetSource): DockerImageAssetLocation { // check if we have an override from context const repositoryNameOverride = this.boundStack.node.tryGetContext(ASSETS_ECR_REPOSITORY_NAME_OVERRIDE_CONTEXT_KEY); diff --git a/packages/@aws-cdk/core/lib/stack-synthesizers/types.ts b/packages/@aws-cdk/core/lib/stack-synthesizers/types.ts index 18c437da224da..6fa04b14cbcb3 100644 --- a/packages/@aws-cdk/core/lib/stack-synthesizers/types.ts +++ b/packages/@aws-cdk/core/lib/stack-synthesizers/types.ts @@ -16,7 +16,7 @@ export interface IStackSynthesizer { /** * Bind to the stack this environment is going to be used on * - * Must be called before any of the other methods are called. + * Must be called before any of the other methods are called, and can only be called once. */ bind(stack: Stack): void; @@ -40,6 +40,33 @@ export interface IStackSynthesizer { synthesize(session: ISynthesisSession): void; } +/** + * Interface for Stack Synthesizers that can be used for more than one stack. + * + * Regular `IStackSynthesizer` instances can only be bound to a Stack once. + * `IReusableStackSynthesizer` instances. + * + * For backwards compatibility reasons, this class inherits from + * `IStackSynthesizer`, but if an object implements `IReusableStackSynthesizer`, + * no other methods than `reusableBind()` will be called. + */ +export interface IReusableStackSynthesizer extends IStackSynthesizer { + /** + * Produce a bound Stack Synthesizer for the given stack. + * + * This method may be called more than once on the same object. + */ + reusableBind(stack: Stack): IBoundStackSynthesizer; +} + +/** + * A Stack Synthesizer, obtained from `IReusableStackSynthesizer.` + * + * Just a type alias with a very concrete contract. + */ +export interface IBoundStackSynthesizer extends IStackSynthesizer { +} + /** * Represents a single session of synthesis. Passed into `Construct.synthesize()` methods. */ @@ -61,3 +88,10 @@ export interface ISynthesisSession { */ validateOnSynth?: boolean; } + +/** + * Whether the given Stack Synthesizer is reusable or not + */ +export function isReusableStackSynthesizer(x: IStackSynthesizer): x is IReusableStackSynthesizer { + return !!(x as any).reusableBind; +} \ No newline at end of file diff --git a/packages/@aws-cdk/core/lib/stack.ts b/packages/@aws-cdk/core/lib/stack.ts index 660f841aead19..8184b6a91abad 100644 --- a/packages/@aws-cdk/core/lib/stack.ts +++ b/packages/@aws-cdk/core/lib/stack.ts @@ -123,8 +123,17 @@ export interface StackProps { /** * Synthesis method to use while deploying this stack * - * @default - `DefaultStackSynthesizer` if the `@aws-cdk/core:newStyleStackSynthesis` feature flag - * is set, `LegacyStackSynthesizer` otherwise. + * The Stack Synthesizer controls aspects of synthesis and deployment, + * like how assets are referenced and what IAM roles to use. For more + * information, see the README of the main CDK package. + * + * If not specified, the `defaultStackSynthesizer` from `App` will be used. + * If that is not specified, `DefaultStackSynthesizer` is used if + * `@aws-cdk/core:newStyleStackSynthesis` is set to `true` or the CDK major + * version is v2. In CDK v1 `LegacyStackSynthesizer` is the default if no + * other synthesizer is specified. + * + * @default - The synthesizer specified on `App`, or `DefaultStackSynthesizer` otherwise. */ readonly synthesizer?: IStackSynthesizer; @@ -230,14 +239,14 @@ export class Stack extends Construct implements ITaggable { * This value is resolved according to the following rules: * * 1. The value provided to `env.region` when the stack is defined. This can - * either be a concerete region (e.g. `us-west-2`) or the `Aws.REGION` + * either be a concrete region (e.g. `us-west-2`) or the `Aws.REGION` * token. * 3. `Aws.REGION`, which is represents the CloudFormation intrinsic reference * `{ "Ref": "AWS::Region" }` encoded as a string token. * * Preferably, you should use the return value as an opaque string and not * attempt to parse it to implement your logic. If you do, you must first - * check that it is a concerete value an not an unresolved token. If this + * check that it is a concrete value an not an unresolved token. If this * value is an unresolved token (`Token.isUnresolved(stack.region)` returns * `true`), this implies that the user wishes that this stack will synthesize * into a **region-agnostic template**. In this case, your code should either @@ -259,7 +268,7 @@ export class Stack extends Construct implements ITaggable { * * Preferably, you should use the return value as an opaque string and not * attempt to parse it to implement your logic. If you do, you must first - * check that it is a concerete value an not an unresolved token. If this + * check that it is a concrete value an not an unresolved token. If this * value is an unresolved token (`Token.isUnresolved(stack.account)` returns * `true`), this implies that the user wishes that this stack will synthesize * into a **account-agnostic template**. In this case, your code should either @@ -427,10 +436,18 @@ export class Stack extends Construct implements ITaggable { this._versionReportingEnabled = (props.analyticsReporting ?? this.node.tryGetContext(cxapi.ANALYTICS_REPORTING_ENABLED_CONTEXT)) && !this.nestedStackParent; - this.synthesizer = props.synthesizer ?? (newStyleSynthesisContext - ? new DefaultStackSynthesizer() - : new LegacyStackSynthesizer()); - this.synthesizer.bind(this); + const synthesizer = (props.synthesizer + ?? this.node.tryGetContext(PRIVATE_CONTEXT_DEFAULT_STACK_SYNTHESIZER) + ?? (newStyleSynthesisContext ? new DefaultStackSynthesizer() : new LegacyStackSynthesizer())); + + if (isReusableStackSynthesizer(synthesizer)) { + // Produce a fresh instance for each stack (should have been the default behavior) + this.synthesizer = synthesizer.reusableBind(this); + } else { + // Bind the single instance in-place to the current stack (backwards compat) + this.synthesizer = synthesizer; + this.synthesizer.bind(this); + } props.permissionsBoundary?._bind(this); @@ -1691,7 +1708,7 @@ import { FileSystem } from './fs'; import { Names } from './names'; import { Reference } from './reference'; import { IResolvable } from './resolvable'; -import { DefaultStackSynthesizer, IStackSynthesizer, ISynthesisSession, LegacyStackSynthesizer, BOOTSTRAP_QUALIFIER_CONTEXT } from './stack-synthesizers'; +import { DefaultStackSynthesizer, IStackSynthesizer, ISynthesisSession, LegacyStackSynthesizer, BOOTSTRAP_QUALIFIER_CONTEXT, isReusableStackSynthesizer } from './stack-synthesizers'; import { StringSpecializer } from './stack-synthesizers/_shared'; import { Stage } from './stage'; import { ITaggable, TagManager } from './tag-manager'; @@ -1699,4 +1716,5 @@ import { Token, Tokenization } from './token'; import { getExportable } from './private/refs'; import { Fact, RegionInfo } from '@aws-cdk/region-info'; import { deployTimeLookup } from './private/region-lookup'; -import { makeUniqueResourceName } from './private/unique-resource-name'; +import { makeUniqueResourceName } from './private/unique-resource-name';import { PRIVATE_CONTEXT_DEFAULT_STACK_SYNTHESIZER } from './private/private-context'; + diff --git a/packages/@aws-cdk/core/package.json b/packages/@aws-cdk/core/package.json index 9821ec4495478..705dfa5fb96da 100644 --- a/packages/@aws-cdk/core/package.json +++ b/packages/@aws-cdk/core/package.json @@ -126,6 +126,8 @@ "construct-interface-extends-iconstruct:@aws-cdk/core.ICustomResourceProvider", "props-physical-name:@aws-cdk/core.CustomResourceProps", "integ-return-type:@aws-cdk/core.IStackSynthesizer.bind", + "integ-return-type:@aws-cdk/core.IBoundStackSynthesizer.bind", + "integ-return-type:@aws-cdk/core.IReusableStackSynthesizer.bind", "props-no-any:@aws-cdk/core.CfnJsonProps.value" ] }, diff --git a/packages/@aws-cdk/core/test/stack-synthesis/clicreds-synthesis.test.ts b/packages/@aws-cdk/core/test/stack-synthesis/clicreds-synthesis.test.ts index 3fab5ef7e0b5f..84229aa34e7fd 100644 --- a/packages/@aws-cdk/core/test/stack-synthesis/clicreds-synthesis.test.ts +++ b/packages/@aws-cdk/core/test/stack-synthesis/clicreds-synthesis.test.ts @@ -207,16 +207,15 @@ describe('CLI creds synthesis', () => { expect(imageTag).toEqual('test-prefix-docker-asset-hash'); }); - test('cannot use same synthesizer for multiple stacks', () => { + test('can use same synthesizer for multiple stacks', () => { // GIVEN const synthesizer = new CliCredentialsStackSynthesizer(); // WHEN new Stack(app, 'Stack2', { synthesizer }); - expect(() => { - new Stack(app, 'Stack3', { synthesizer }); - }).toThrow(/A StackSynthesizer can only be used for one Stack/); + new Stack(app, 'Stack3', { synthesizer }); + app.synth(); }); }); diff --git a/packages/@aws-cdk/core/test/stack-synthesis/new-style-synthesis.test.ts b/packages/@aws-cdk/core/test/stack-synthesis/new-style-synthesis.test.ts index 0208d01e42bb9..2be3a7e008cd7 100644 --- a/packages/@aws-cdk/core/test/stack-synthesis/new-style-synthesis.test.ts +++ b/packages/@aws-cdk/core/test/stack-synthesis/new-style-synthesis.test.ts @@ -12,9 +12,10 @@ const CFN_CONTEXT = { 'AWS::URLSuffix': 'domain.aws', }; -let app: App; -let stack: Stack; describe('new style synthesis', () => { + let app: App; + let stack: Stack; + beforeEach(() => { app = new App({ context: { @@ -400,17 +401,64 @@ describe('new style synthesis', () => { expect(imageTag).toEqual('test-prefix-docker-asset-hash'); }); - test('cannot use same synthesizer for multiple stacks', () => { + test('can use same synthesizer for multiple stacks', () => { // GIVEN - const synthesizer = new DefaultStackSynthesizer(); + const synthesizer = new DefaultStackSynthesizer({ + bootstrapStackVersionSsmParameter: 'bleep', + }); // WHEN - new Stack(app, 'Stack2', { synthesizer }); - expect(() => { - new Stack(app, 'Stack3', { synthesizer }); - }).toThrow(/A StackSynthesizer can only be used for one Stack/); + const stack1 = new Stack(app, 'Stack1', { synthesizer }); + const stack2 = new Stack(app, 'Stack2', { synthesizer }); + // THEN + const asm = app.synth(); + for (const st of [stack1, stack2]) { + const tpl = asm.getStackByName(st.stackName).template; + expect(tpl).toEqual(expect.objectContaining({ + Parameters: expect.objectContaining({ + BootstrapVersion: expect.objectContaining({ + Default: 'bleep', // Assert that the settings have been applied + }), + }), + })); + } }); + + /** + * Evaluate a possibly string-containing value the same way CFN would do + * + * (Be invariant to the specific Fn::Sub or Fn::Join we would output) + */ + function evalCFN(value: any) { + return evaluateCFN(stack.resolve(value), CFN_CONTEXT); + } +}); + +test('can specify synthesizer at the app level', () => { + // GIVEN + const app = new App({ + defaultStackSynthesizer: new DefaultStackSynthesizer({ + bootstrapStackVersionSsmParameter: 'bleep', + }), + }); + + // WHEN + const stack1 = new Stack(app, 'Stack1'); + const stack2 = new Stack(app, 'Stack2'); + + // THEN + const asm = app.synth(); + for (const st of [stack1, stack2]) { + const tpl = asm.getStackByName(st.stackName).template; + expect(tpl).toEqual(expect.objectContaining({ + Parameters: expect.objectContaining({ + BootstrapVersion: expect.objectContaining({ + Default: 'bleep', // Assert that the settings have been applied + }), + }), + })); + } }); test('get an exception when using tokens for parameters', () => { @@ -422,15 +470,6 @@ test('get an exception when using tokens for parameters', () => { }).toThrow(/cannot contain tokens/); }); -/** - * Evaluate a possibly string-containing value the same way CFN would do - * - * (Be invariant to the specific Fn::Sub or Fn::Join we would output) - */ -function evalCFN(value: any) { - return evaluateCFN(stack.resolve(value), CFN_CONTEXT); -} - function isAssetManifest(x: cxapi.CloudArtifact): x is cxapi.AssetManifestArtifact { return x instanceof cxapi.AssetManifestArtifact; } diff --git a/packages/@aws-cdk/pipelines/README.md b/packages/@aws-cdk/pipelines/README.md index 05996b52c4ac2..91ec38e0f4184 100644 --- a/packages/@aws-cdk/pipelines/README.md +++ b/packages/@aws-cdk/pipelines/README.md @@ -525,12 +525,15 @@ pipeline. This will encrypt the artifact bucket(s), but incurs a cost for maintaining the KMS key. +You may also wish to enable automatic key rotation for the created KMS key. + Example: ```ts const pipeline = new pipelines.CodePipeline(this, 'Pipeline', { // Encrypt artifacts, required for cross-account deployments crossAccountKeys: true, + enableKeyRotation: true, // optional synth: new pipelines.ShellStep('Synth', { input: pipelines.CodePipelineSource.connection('my-org/my-app', 'main', { connectionArn: 'arn:aws:codestar-connections:us-east-1:222222222222:connection/7d2469ff-514a-4e4f-9003-5ca4a43cdc41', // Created using the AWS console * });', diff --git a/packages/@aws-cdk/pipelines/lib/codepipeline/codepipeline.ts b/packages/@aws-cdk/pipelines/lib/codepipeline/codepipeline.ts index 6eac94489539f..5fae734d240df 100644 --- a/packages/@aws-cdk/pipelines/lib/codepipeline/codepipeline.ts +++ b/packages/@aws-cdk/pipelines/lib/codepipeline/codepipeline.ts @@ -225,6 +225,16 @@ export interface CodePipelineProps { * @default true */ readonly useChangeSets?: boolean; + + /** + * Enable KMS key rotation for the generated KMS keys. + * + * By default KMS key rotation is disabled, but will add + * additional costs when enabled. + * + * @default - false (key rotation is disabled) + */ + readonly enableKeyRotation?: boolean; } /** @@ -381,6 +391,9 @@ export class CodePipeline extends PipelineBase { if (this.props.crossAccountKeys !== undefined) { throw new Error('Cannot set \'crossAccountKeys\' if an existing CodePipeline is given using \'codePipeline\''); } + if (this.props.enableKeyRotation !== undefined) { + throw new Error('Cannot set \'enableKeyRotation\' if an existing CodePipeline is given using \'codePipeline\''); + } if (this.props.reuseCrossRegionSupportStacks !== undefined) { throw new Error('Cannot set \'reuseCrossRegionSupportStacks\' if an existing CodePipeline is given using \'codePipeline\''); } @@ -398,6 +411,7 @@ export class CodePipeline extends PipelineBase { // to happen only after the builds of the latest pipeline definition). restartExecutionOnUpdate: true, role: this.props.role, + enableKeyRotation: this.props.enableKeyRotation, }); } diff --git a/packages/@aws-cdk/pipelines/lib/helpers-internal/graph.ts b/packages/@aws-cdk/pipelines/lib/helpers-internal/graph.ts index 798cc207f0aeb..7ff5208a410ae 100644 --- a/packages/@aws-cdk/pipelines/lib/helpers-internal/graph.ts +++ b/packages/@aws-cdk/pipelines/lib/helpers-internal/graph.ts @@ -73,6 +73,14 @@ export class GraphNode { return x; } + public get rootGraph(): Graph { + const root = this.root; + if (!(root instanceof Graph)) { + throw new Error(`Expecting a graph as root, got: ${root}`); + } + return root; + } + public get parentGraph() { return this._parentGraph; } @@ -93,50 +101,103 @@ export class GraphNode { } /** - * A dependency set that can be constructed partially and later finished + * A dependency set that is constructed over time * * It doesn't matter in what order sources and targets for the dependency * relationship(s) get added. This class can serve as a synchronization * point if the order in which graph nodes get added to the graph is not * well-defined. * - * Useful utility during graph building. + * You can think of a DependencyBuilder as a vertex that doesn't actually exist in the tree: + * + * ┌────┐ ┌────┐ + * │ P1 │◀─┐ ┌──│ S1 │ + * └────┘ │ .─. │ └────┘ + * ├──( B )◀─┤ + * ┌────┐ │ `─' │ ┌────┐ + * │ P2 │◀─┘ └──│ S2 │ + * └────┘ └────┘ + * + * Ultimately leads to: { S1 -> P1, S1 -> P2, S2 -> P1, S2 -> P2 }. */ export class DependencyBuilder { - private readonly targets: GraphNode[] = []; - private readonly sources: GraphNode[] = []; + private readonly _producers: GraphNode[] = []; + private readonly _consumers: GraphNode[] = []; + /** + * Add a producer: make all nodes added by 'dependBy' depend on these + */ public dependOn(...targets: GraphNode[]) { for (const target of targets) { - for (const source of this.sources) { + for (const source of this._consumers) { source.dependOn(target); } - this.targets.push(target); + this._producers.push(target); } return this; } + /** + * Add a consumer: make these nodes depend on all nodes added by 'dependOn'. + */ public dependBy(...sources: GraphNode[]) { for (const source of sources) { - for (const target of this.targets) { + for (const target of this._producers) { source.dependOn(target); } - this.sources.push(source); + this._consumers.push(source); } return this; } + + /** + * Whether there are any consumers (nodes added by 'dependBy') but no producers (nodes added by 'dependOn') + */ + public get hasUnsatisfiedConsumers() { + return this._consumers.length > 0 && this._producers.length === 0; + } + + public get consumers(): ReadonlyArray> { + return this._consumers; + } + + public consumersAsString() { + return this.consumers.map(c => `${c}`).join(','); + } } -export class DependencyBuilders { +/** + * A set of dependency builders identified by a given key. + */ +export class DependencyBuilders { private readonly builders = new Map>(); - public get(key: K) { + public for(key: K) { const b = this.builders.get(key); if (b) { return b; } const ret = new DependencyBuilder(); this.builders.set(key, ret); return ret; } + + /** + * @deprecated Use 'for' + */ + public get(key: K) { + return this.for(key); + } + + public unsatisfiedBuilders() { + const ret = new Array<[K, DependencyBuilder]>(); + + for (const [k, builder] of this.builders.entries()) { + if (builder.hasUnsatisfiedConsumers) { + ret.push([k, builder]); + } + } + + return ret; + } } export interface GraphProps extends GraphNodeProps { @@ -304,12 +365,32 @@ export class GraphNodeCollection { this.nodes = Array.from(nodes); } + /** + * Add one or more dependencies to all nodes in the collection + */ public dependOn(...dependencies: Array | undefined>) { for (const node of this.nodes) { node.dependOn(...dependencies.filter(isDefined)); } } + /** + * Return the topographically first node in the collection + */ + public first() { + const nodes = new Set(this.nodes); + const sorted = this.nodes[0].rootGraph.sortedLeaves(); + for (const tranche of sorted) { + for (const node of tranche) { + if (nodes.has(node)) { + return node; + } + } + } + + throw new Error(`Could not calculate first node between ${this}`); + } + /** * Returns the graph node that's shared between these nodes */ @@ -351,6 +432,10 @@ export class GraphNodeCollection { return paths[0][0]; } + + public toString() { + return this.nodes.map(n => `${n}`).join(', '); + } } /** diff --git a/packages/@aws-cdk/pipelines/lib/helpers-internal/pipeline-graph.ts b/packages/@aws-cdk/pipelines/lib/helpers-internal/pipeline-graph.ts index a411a2dfc547a..cc245cd58e4d4 100644 --- a/packages/@aws-cdk/pipelines/lib/helpers-internal/pipeline-graph.ts +++ b/packages/@aws-cdk/pipelines/lib/helpers-internal/pipeline-graph.ts @@ -54,7 +54,9 @@ export class PipelineGraph { private readonly assetNodesByType = new Map(); private readonly synthNode?: AGraphNode; private readonly selfMutateNode?: AGraphNode; - private readonly stackOutputDependencies = new DependencyBuilders(); + private readonly stackOutputDependencies = new DependencyBuilders(); + /** Mapping steps to depbuilders, satisfied by the step itself */ + private readonly nodeDependencies = new DependencyBuilders(); private readonly publishTemplate: boolean; private readonly prepareStep: boolean; private readonly singlePublisher: boolean; @@ -102,8 +104,7 @@ export class PipelineGraph { waves[i].dependOn(waves[i - 1]); } - // Add additional dependencies between steps that depend on stack outputs and the stacks - // that produce them. + this.addMissingDependencyNodes(); } public isSynthNode(node: AGraphNode) { @@ -111,7 +112,7 @@ export class PipelineGraph { } private addBuildStep(step: Step) { - return this.addAndRecurse(step, this.topLevelGraph('Build')); + return this.addStepNode(step, this.topLevelGraph('Build')); } private addWave(wave: Wave): AGraph { @@ -174,7 +175,7 @@ export class PipelineGraph { const cloudAssembly = this.cloudAssemblyFileSet; - firstDeployNode.dependOn(this.addAndRecurse(cloudAssembly.producer, retGraph)); + firstDeployNode.dependOn(this.addStepNode(cloudAssembly.producer, retGraph)); // add the template asset if (this.publishTemplate) { @@ -195,7 +196,7 @@ export class PipelineGraph { // Add stack output synchronization point if (this.queries.stackOutputsReferenced(stack).length > 0) { - this.stackOutputDependencies.get(stack).dependOn(deployNode); + this.stackOutputDependencies.for(stack).dependOn(deployNode); } } @@ -220,7 +221,7 @@ export class PipelineGraph { private addChangeSetNode(changeSet: Step[], prepareNode: AGraphNode, deployNode: AGraphNode, graph: AGraph) { for (const c of changeSet) { - const changeSetNode = this.addAndRecurse(c, graph); + const changeSetNode = this.addStepNode(c, graph); changeSetNode?.dependOn(prepareNode); deployNode.dependOn(changeSetNode); } @@ -230,12 +231,12 @@ export class PipelineGraph { const currentNodes = new GraphNodeCollection(parent.nodes); const preNodes = new GraphNodeCollection(new Array()); for (const p of pre) { - const preNode = this.addAndRecurse(p, parent); + const preNode = this.addStepNode(p, parent); currentNodes.dependOn(preNode); preNodes.nodes.push(preNode!); } for (const p of post) { - const postNode = this.addAndRecurse(p, parent); + const postNode = this.addStepNode(p, parent); postNode?.dependOn(...currentNodes.nodes); } return preNodes; @@ -250,7 +251,12 @@ export class PipelineGraph { return ret as AGraph; } - private addAndRecurse(step: Step, parent: AGraph) { + /** + * Add a Node to a Graph for a given Step + * + * Adds all dependencies for that Node to the same Step as well. + */ + private addStepNode(step: Step, parent: AGraph) { if (step === PipelineGraph.NO_STEP) { return undefined; } const previous = this.added.get(step); @@ -267,21 +273,56 @@ export class PipelineGraph { parent.add(node); this.added.set(step, node); + // This used to recurse -- that's not safe, because it might create nodes in the + // wrong graph (it would create a dependency node, that might need to be created in + // a different graph, in the current one). Instead, use DependencyBuilders. for (const dep of step.dependencies) { - const producerNode = this.addAndRecurse(dep, parent); - node.dependOn(producerNode); + this.nodeDependencies.for(dep).dependBy(node); } + this.nodeDependencies.for(step).dependOn(node); // Add stack dependencies (by use of the dependency builder this also works // if we encounter the Step before the Stack has been properly added yet) for (const output of step.consumedStackOutputs) { const stack = this.queries.producingStack(output); - this.stackOutputDependencies.get(stack).dependBy(node); + this.stackOutputDependencies.for(stack).dependBy(node); } return node; } + /** + * Add dependencies that aren't in the pipeline yet + * + * Build steps reference as many sources (or other builds) as they want, which will be added + * automatically. Do that here. We couldn't do it earlier, because if there were dependencies + * between steps we didn't want to reparent those unnecessarily. + */ + private addMissingDependencyNodes() { + // May need to do this more than once to recursively add all missing producers + let attempts = 20; + while (attempts-- > 0) { + const unsatisfied = this.nodeDependencies.unsatisfiedBuilders().filter(([s]) => s !== PipelineGraph.NO_STEP); + if (unsatisfied.length === 0) { return; } + + for (const [step, builder] of unsatisfied) { + // Add a new node for this step to the parent of the "leftmost" consumer. + const leftMostConsumer = new GraphNodeCollection(builder.consumers).first(); + const parent = leftMostConsumer.parentGraph; + if (!parent) { + throw new Error(`Consumer doesn't have a parent graph: ${leftMostConsumer}`); + } + this.addStepNode(step, parent); + } + } + + const unsatisfied = this.nodeDependencies.unsatisfiedBuilders(); + throw new Error([ + 'Recursion depth too large while adding dependency nodes:', + unsatisfied.map(([step, builder]) => `${builder.consumersAsString()} awaiting ${step}.`), + ].join(' ')); + } + private publishAsset(stackAsset: StackAsset): AGraphNode { const assetsGraph = this.topLevelGraph('Assets'); diff --git a/packages/@aws-cdk/pipelines/test/blueprint/helpers-internal/pipeline-graph.test.ts b/packages/@aws-cdk/pipelines/test/blueprint/helpers-internal/pipeline-graph.test.ts index 747dcfcb91d77..f473d4e0cf001 100644 --- a/packages/@aws-cdk/pipelines/test/blueprint/helpers-internal/pipeline-graph.test.ts +++ b/packages/@aws-cdk/pipelines/test/blueprint/helpers-internal/pipeline-graph.test.ts @@ -340,8 +340,8 @@ describe('with app with output', () => { }); // WHEN - const graph = new PipelineGraph(blueprint).graph; expect(() => { + const graph = new PipelineGraph(blueprint).graph; assertGraph(nodeAt(graph, 'Alpha')).sortedLeaves(); }).toThrow(/Dependency cycle/); }); diff --git a/packages/@aws-cdk/pipelines/test/codepipeline/codepipeline.test.ts b/packages/@aws-cdk/pipelines/test/codepipeline/codepipeline.test.ts index b0ecae2286d1a..246c3173efc0f 100644 --- a/packages/@aws-cdk/pipelines/test/codepipeline/codepipeline.test.ts +++ b/packages/@aws-cdk/pipelines/test/codepipeline/codepipeline.test.ts @@ -8,7 +8,7 @@ import { Stack } from '@aws-cdk/core'; import { Construct } from 'constructs'; import * as cdkp from '../../lib'; import { CodePipeline } from '../../lib'; -import { PIPELINE_ENV, TestApp, ModernTestGitHubNpmPipeline, FileAssetApp } from '../testhelpers'; +import { PIPELINE_ENV, TestApp, ModernTestGitHubNpmPipeline, FileAssetApp, TwoStackApp } from '../testhelpers'; let app: TestApp; @@ -81,6 +81,11 @@ describe('Providing codePipeline parameter and prop(s) of codePipeline parameter pipelineName: 'randomName', }).create()).toThrowError('Cannot set \'pipelineName\' if an existing CodePipeline is given using \'codePipeline\''); }); + test('Providing codePipeline parameter and enableKeyRotation parameter should throw error', () => { + expect(() => new CodePipelinePropsCheckTest(app, 'CodePipeline', { + enableKeyRotation: true, + }).create()).toThrowError('Cannot set \'enableKeyRotation\' if an existing CodePipeline is given using \'codePipeline\''); + }); test('Providing codePipeline parameter and crossAccountKeys parameter should throw error', () => { expect(() => new CodePipelinePropsCheckTest(app, 'CodePipeline', { crossAccountKeys: true, @@ -192,6 +197,60 @@ test('CodeBuild action role has the right AssumeRolePolicyDocument', () => { }); }); +test('CodePipeline throws when key rotation is enabled without enabling cross account keys', ()=>{ + const pipelineStack = new cdk.Stack(app, 'PipelineStack', { env: PIPELINE_ENV }); + const repo = new ccommit.Repository(pipelineStack, 'Repo', { + repositoryName: 'MyRepo', + }); + const cdkInput = cdkp.CodePipelineSource.codeCommit( + repo, + 'main', + ); + + expect(() => new CodePipeline(pipelineStack, 'Pipeline', { + enableKeyRotation: true, + synth: new cdkp.ShellStep('Synth', { + input: cdkInput, + installCommands: ['npm ci'], + commands: [ + 'npm run build', + 'npx cdk synth', + ], + }), + }).buildPipeline()).toThrowError('Setting \'enableKeyRotation\' to true also requires \'crossAccountKeys\' to be enabled'); +}); + + +test('CodePipeline enables key rotation on cross account keys', ()=>{ + const pipelineStack = new cdk.Stack(app, 'PipelineStack', { env: PIPELINE_ENV }); + const repo = new ccommit.Repository(pipelineStack, 'Repo', { + repositoryName: 'MyRepo', + }); + const cdkInput = cdkp.CodePipelineSource.codeCommit( + repo, + 'main', + ); + + new CodePipeline(pipelineStack, 'Pipeline', { + enableKeyRotation: true, + crossAccountKeys: true, // requirement of key rotation + synth: new cdkp.ShellStep('Synth', { + input: cdkInput, + installCommands: ['npm ci'], + commands: [ + 'npm run build', + 'npx cdk synth', + ], + }), + }); + + const template = Template.fromStack(pipelineStack); + + template.hasResourceProperties('AWS::KMS::Key', { + EnableKeyRotation: true, + }); +}); + test('CodePipeline supports use of existing role', () => { const pipelineStack = new cdk.Stack(app, 'PipelineStack', { env: PIPELINE_ENV }); const repo = new ccommit.Repository(pipelineStack, 'Repo', { @@ -298,6 +357,41 @@ describe('deployment of stack', () => { }); }); +test('action name is calculated properly if it has cross-stack dependencies', () => { + // GIVEN + const pipelineStack = new cdk.Stack(app, 'PipelineStack', { env: PIPELINE_ENV }); + const pipeline = new ModernTestGitHubNpmPipeline(pipelineStack, 'Cdk', { + crossAccountKeys: true, + }); + + // WHEN + const s1step = new cdkp.ManualApprovalStep('S1'); + const s2step = new cdkp.ManualApprovalStep('S2'); + s1step.addStepDependency(s2step); + + // The issue we were diagnosing only manifests if the stacks don't have + // a dependency on each other + const stage = new TwoStackApp(app, 'TheApp', { withDependency: false }); + pipeline.addStage(stage, { + stackSteps: [ + { stack: stage.stack1, post: [s1step] }, + { stack: stage.stack2, post: [s2step] }, + ], + }); + + // THEN + const template = Template.fromStack(pipelineStack); + template.hasResourceProperties('AWS::CodePipeline::Pipeline', { + Stages: Match.arrayWith([{ + Name: 'TheApp', + Actions: Match.arrayWith([ + Match.objectLike({ Name: 'Stack2.S2', RunOrder: 3 }), + Match.objectLike({ Name: 'Stack1.S1', RunOrder: 4 }), + ]), + }]), + }); +}); + interface ReuseCodePipelineStackProps extends cdk.StackProps { reuseCrossRegionSupportStacks?: boolean; } @@ -358,6 +452,7 @@ class ReuseStack extends cdk.Stack { interface CodePipelineStackProps extends cdk.StackProps { pipelineName?: string; crossAccountKeys?: boolean; + enableKeyRotation?: boolean; reuseCrossRegionSupportStacks?: boolean; role?: iam.IRole; } @@ -379,21 +474,28 @@ class CodePipelinePropsCheckTest extends cdk.Stack { if (this.cProps.crossAccountKeys !== undefined) { new cdkp.CodePipeline(this, 'CodePipeline2', { crossAccountKeys: this.cProps.crossAccountKeys, - codePipeline: new Pipeline(this, 'Pipline2'), + codePipeline: new Pipeline(this, 'Pipeline2'), synth: new cdkp.ShellStep('Synth', { commands: ['ls'] }), }).buildPipeline(); } - if (this.cProps.reuseCrossRegionSupportStacks !== undefined) { + if (this.cProps.enableKeyRotation !== undefined) { new cdkp.CodePipeline(this, 'CodePipeline3', { + enableKeyRotation: this.cProps.enableKeyRotation, + codePipeline: new Pipeline(this, 'Pipeline3'), + synth: new cdkp.ShellStep('Synth', { commands: ['ls'] }), + }).buildPipeline(); + } + if (this.cProps.reuseCrossRegionSupportStacks !== undefined) { + new cdkp.CodePipeline(this, 'CodePipeline4', { reuseCrossRegionSupportStacks: this.cProps.reuseCrossRegionSupportStacks, - codePipeline: new Pipeline(this, 'Pipline3'), + codePipeline: new Pipeline(this, 'Pipeline4'), synth: new cdkp.ShellStep('Synth', { commands: ['ls'] }), }).buildPipeline(); } if (this.cProps.role !== undefined) { - new cdkp.CodePipeline(this, 'CodePipeline4', { + new cdkp.CodePipeline(this, 'CodePipeline5', { role: this.cProps.role, - codePipeline: new Pipeline(this, 'Pipline4'), + codePipeline: new Pipeline(this, 'Pipeline5'), synth: new cdkp.ShellStep('Synth', { commands: ['ls'] }), }).buildPipeline(); } diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/LambdaTestDefaultTestDeployAssert1AF2B360.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/LambdaTestDefaultTestDeployAssert1AF2B360.assets.json new file mode 100644 index 0000000000000..94246814e0a48 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/LambdaTestDefaultTestDeployAssert1AF2B360.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22": { + "source": { + "path": "LambdaTestDefaultTestDeployAssert1AF2B360.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/LambdaTestDefaultTestDeployAssert1AF2B360.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/LambdaTestDefaultTestDeployAssert1AF2B360.template.json new file mode 100644 index 0000000000000..ad9d0fb73d1dd --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/LambdaTestDefaultTestDeployAssert1AF2B360.template.json @@ -0,0 +1,36 @@ +{ + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/PipelineStack.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/PipelineStack.assets.json new file mode 100644 index 0000000000000..af32741f7bc44 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/PipelineStack.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "c1bda7e2c84e91a5658af0b194a4c8918dead52ad783e29acbc3701149e73f45": { + "source": { + "path": "PipelineStack.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "c1bda7e2c84e91a5658af0b194a4c8918dead52ad783e29acbc3701149e73f45.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/PipelineStack.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/PipelineStack.template.json new file mode 100644 index 0000000000000..855088e557cb5 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/PipelineStack.template.json @@ -0,0 +1,2546 @@ +{ + "Resources": { + "PipelineArtifactsBucketEncryptionKeyF5BF0670": { + "Type": "AWS::KMS::Key", + "Properties": { + "KeyPolicy": { + "Statement": [ + { + "Action": "kms:*", + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": "*" + }, + { + "Action": [ + "kms:Decrypt", + "kms:DescribeKey" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + "Resource": "*" + } + ], + "Version": "2012-10-17" + }, + "EnableKeyRotation": true + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + }, + "PipelineArtifactsBucketEncryptionKeyAlias94A07392": { + "Type": "AWS::KMS::Alias", + "Properties": { + "AliasName": "alias/codepipeline-pipelinestack-pipeline-e95eedaa", + "TargetKeyId": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + }, + "PipelineArtifactsBucketAEA9A052": { + "Type": "AWS::S3::Bucket", + "Properties": { + "BucketEncryption": { + "ServerSideEncryptionConfiguration": [ + { + "ServerSideEncryptionByDefault": { + "KMSMasterKeyID": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + }, + "SSEAlgorithm": "aws:kms" + } + } + ] + }, + "PublicAccessBlockConfiguration": { + "BlockPublicAcls": true, + "BlockPublicPolicy": true, + "IgnorePublicAcls": true, + "RestrictPublicBuckets": true + } + }, + "UpdateReplacePolicy": "Retain", + "DeletionPolicy": "Retain" + }, + "PipelineArtifactsBucketPolicyF53CCC52": { + "Type": "AWS::S3::BucketPolicy", + "Properties": { + "Bucket": { + "Ref": "PipelineArtifactsBucketAEA9A052" + }, + "PolicyDocument": { + "Statement": [ + { + "Action": "s3:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "s3:GetBucket*", + "s3:GetObject*", + "s3:List*" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + "Resource": [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + } + ], + "Version": "2012-10-17" + } + } + }, + "PipelineRoleB27FAA37": { + "Type": "AWS::IAM::Role", + "Properties": { + "AssumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "codepipeline.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + } + } + }, + "PipelineRoleDefaultPolicy7BDC1ABB": { + "Type": "AWS::IAM::Policy", + "Properties": { + "PolicyDocument": { + "Statement": [ + { + "Action": [ + "s3:Abort*", + "s3:DeleteObject*", + "s3:GetBucket*", + "s3:GetObject*", + "s3:List*", + "s3:PutObject", + "s3:PutObjectLegalHold", + "s3:PutObjectRetention", + "s3:PutObjectTagging", + "s3:PutObjectVersionTagging" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "kms:Decrypt", + "kms:DescribeKey", + "kms:Encrypt", + "kms:GenerateDataKey*", + "kms:ReEncrypt*" + ], + "Effect": "Allow", + "Resource": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + } + }, + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Resource": [ + { + "Fn::GetAtt": [ + "PipelineCodeBuildActionRole226DB0CB", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + ] + } + ], + "Version": "2012-10-17" + }, + "PolicyName": "PipelineRoleDefaultPolicy7BDC1ABB", + "Roles": [ + { + "Ref": "PipelineRoleB27FAA37" + } + ] + } + }, + "Pipeline9850B417": { + "Type": "AWS::CodePipeline::Pipeline", + "Properties": { + "RoleArn": { + "Fn::GetAtt": [ + "PipelineRoleB27FAA37", + "Arn" + ] + }, + "Stages": [ + { + "Actions": [ + { + "ActionTypeId": { + "Category": "Source", + "Owner": "ThirdParty", + "Provider": "GitHub", + "Version": "1" + }, + "Configuration": { + "Owner": "tkglaser", + "Repo": "cdk-pipelines-demo", + "Branch": "main", + "OAuthToken": "{{resolve:secretsmanager:github-token:SecretString:::}}", + "PollForSourceChanges": false + }, + "Name": "tkglaser_cdk-pipelines-demo", + "OutputArtifacts": [ + { + "Name": "tkglaser_cdk_pipelines_demo_Source" + } + ], + "RunOrder": 1 + } + ], + "Name": "Source" + }, + { + "Actions": [ + { + "ActionTypeId": { + "Category": "Build", + "Owner": "AWS", + "Provider": "CodeBuild", + "Version": "1" + }, + "Configuration": { + "ProjectName": { + "Ref": "PipelineBuildSynthCdkBuildProject6BEFA8E6" + }, + "EnvironmentVariables": "[{\"name\":\"_PROJECT_CONFIG_HASH\",\"type\":\"PLAINTEXT\",\"value\":\"00ebacfb32b1bde8d3638577308e7b7144dfa3b0a58a83bc6ff38a3b1f26951c\"}]" + }, + "InputArtifacts": [ + { + "Name": "tkglaser_cdk_pipelines_demo_Source" + } + ], + "Name": "Synth", + "OutputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "RoleArn": { + "Fn::GetAtt": [ + "PipelineCodeBuildActionRole226DB0CB", + "Arn" + ] + }, + "RunOrder": 1 + } + ], + "Name": "Build" + }, + { + "Actions": [ + { + "ActionTypeId": { + "Category": "Build", + "Owner": "AWS", + "Provider": "CodeBuild", + "Version": "1" + }, + "Configuration": { + "ProjectName": { + "Ref": "PipelineUpdatePipelineSelfMutationDAA41400" + }, + "EnvironmentVariables": "[{\"name\":\"_PROJECT_CONFIG_HASH\",\"type\":\"PLAINTEXT\",\"value\":\"c0779bd925c3a7f19be75a4973c668d10d00ce3552b882c7d2ba3fa3cee6d976\"}]" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "SelfMutate", + "RoleArn": { + "Fn::GetAtt": [ + "PipelineCodeBuildActionRole226DB0CB", + "Arn" + ] + }, + "RunOrder": 1 + } + ], + "Name": "UpdatePipeline" + }, + { + "Actions": [ + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Beta-Stack1", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Beta/PipelineStackBetaStack1E6541489.template.json" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "Stack1.Prepare", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 1 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Beta-Stack1", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "Name": "Stack1.Deploy", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 2 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Beta-Stack2", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Beta/PipelineStackBetaStack2C79AD00A.template.json" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "Stack2.Prepare", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 3 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Beta-Stack2", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "Name": "Stack2.Deploy", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 4 + } + ], + "Name": "Beta" + }, + { + "Actions": [ + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod1-Stack1", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod1/PipelineStackProd1Stack14013D698.template.json" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "Prod1.Stack1.Prepare", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 1 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod2-Stack1", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod2/PipelineStackProd2Stack1FD464162.template.json" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "Prod2.Stack1.Prepare", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 1 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod1-Stack1", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "Name": "Prod1.Stack1.Deploy", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 2 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod2-Stack1", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "Name": "Prod2.Stack1.Deploy", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 2 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod1-Stack2", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod1/PipelineStackProd1Stack2F0681AFF.template.json" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "Prod1.Stack2.Prepare", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 3 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod2-Stack2", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod2/PipelineStackProd2Stack2176123EB.template.json" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "Prod2.Stack2.Prepare", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 3 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod1-Stack2", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "Name": "Prod1.Stack2.Deploy", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 4 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod2-Stack2", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "Name": "Prod2.Stack2.Deploy", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 4 + } + ], + "Name": "Wave1" + }, + { + "Actions": [ + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod3-Stack1", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod3/PipelineStackProd3Stack1795F3D43.template.json" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "Prod3.Stack1.Prepare", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 1 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod4-Stack1", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod4/PipelineStackProd4Stack118F74ADB.template.json" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "Prod4.Stack1.Prepare", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 1 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod5-Stack1", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod5/PipelineStackProd5Stack1E7E4E4C6.template.json" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "Prod5.Stack1.Prepare", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 1 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod6-Stack1", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod6/PipelineStackProd6Stack1E7C34314.template.json" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "Prod6.Stack1.Prepare", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 1 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod3-Stack1", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "Name": "Prod3.Stack1.Deploy", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 2 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod4-Stack1", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "Name": "Prod4.Stack1.Deploy", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 2 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod5-Stack1", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "Name": "Prod5.Stack1.Deploy", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 2 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod6-Stack1", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "Name": "Prod6.Stack1.Deploy", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 2 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod3-Stack2", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod3/PipelineStackProd3Stack2DFBBA0B2.template.json" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "Prod3.Stack2.Prepare", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 3 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod4-Stack2", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod4/PipelineStackProd4Stack2E2CB4ED3.template.json" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "Prod4.Stack2.Prepare", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 3 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod5-Stack2", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod5/PipelineStackProd5Stack2C39BEE5B.template.json" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "Prod5.Stack2.Prepare", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 3 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod6-Stack2", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod6/PipelineStackProd6Stack2BED1BBCE.template.json" + }, + "InputArtifacts": [ + { + "Name": "Synth_Output" + } + ], + "Name": "Prod6.Stack2.Prepare", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 3 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod3-Stack2", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "Name": "Prod3.Stack2.Deploy", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 4 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod4-Stack2", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "Name": "Prod4.Stack2.Deploy", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 4 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod5-Stack2", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "Name": "Prod5.Stack2.Deploy", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 4 + }, + { + "ActionTypeId": { + "Category": "Deploy", + "Owner": "AWS", + "Provider": "CloudFormation", + "Version": "1" + }, + "Configuration": { + "StackName": "Prod6-Stack2", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "Name": "Prod6.Stack2.Deploy", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "RunOrder": 4 + } + ], + "Name": "Wave2" + } + ], + "ArtifactStore": { + "EncryptionKey": { + "Id": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + }, + "Type": "KMS" + }, + "Location": { + "Ref": "PipelineArtifactsBucketAEA9A052" + }, + "Type": "S3" + }, + "RestartExecutionOnUpdate": true + }, + "DependsOn": [ + "PipelineRoleDefaultPolicy7BDC1ABB", + "PipelineRoleB27FAA37" + ] + }, + "PipelineSourcetkglasercdkpipelinesdemoWebhookResource54EE51BE": { + "Type": "AWS::CodePipeline::Webhook", + "Properties": { + "Authentication": "GITHUB_HMAC", + "AuthenticationConfiguration": { + "SecretToken": "{{resolve:secretsmanager:github-token:SecretString:::}}" + }, + "Filters": [ + { + "JsonPath": "$.ref", + "MatchEquals": "refs/heads/{Branch}" + } + ], + "TargetAction": "tkglaser_cdk-pipelines-demo", + "TargetPipeline": { + "Ref": "Pipeline9850B417" + }, + "TargetPipelineVersion": 1, + "RegisterWithThirdParty": true + } + }, + "PipelineBuildSynthCdkBuildProjectRole231EEA2A": { + "Type": "AWS::IAM::Role", + "Properties": { + "AssumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "codebuild.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + } + } + }, + "PipelineBuildSynthCdkBuildProjectRoleDefaultPolicyFB6C941C": { + "Type": "AWS::IAM::Policy", + "Properties": { + "PolicyDocument": { + "Statement": [ + { + "Action": [ + "logs:CreateLogGroup", + "logs:CreateLogStream", + "logs:PutLogEvents" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/codebuild/", + { + "Ref": "PipelineBuildSynthCdkBuildProject6BEFA8E6" + }, + ":*" + ] + ] + }, + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/codebuild/", + { + "Ref": "PipelineBuildSynthCdkBuildProject6BEFA8E6" + } + ] + ] + } + ] + }, + { + "Action": [ + "codebuild:BatchPutCodeCoverages", + "codebuild:BatchPutTestCases", + "codebuild:CreateReport", + "codebuild:CreateReportGroup", + "codebuild:UpdateReport" + ], + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":codebuild:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":report-group/", + { + "Ref": "PipelineBuildSynthCdkBuildProject6BEFA8E6" + }, + "-*" + ] + ] + } + }, + { + "Action": [ + "s3:Abort*", + "s3:DeleteObject*", + "s3:GetBucket*", + "s3:GetObject*", + "s3:List*", + "s3:PutObject", + "s3:PutObjectLegalHold", + "s3:PutObjectRetention", + "s3:PutObjectTagging", + "s3:PutObjectVersionTagging" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "kms:Decrypt", + "kms:DescribeKey", + "kms:Encrypt", + "kms:GenerateDataKey*", + "kms:ReEncrypt*" + ], + "Effect": "Allow", + "Resource": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + } + } + ], + "Version": "2012-10-17" + }, + "PolicyName": "PipelineBuildSynthCdkBuildProjectRoleDefaultPolicyFB6C941C", + "Roles": [ + { + "Ref": "PipelineBuildSynthCdkBuildProjectRole231EEA2A" + } + ] + } + }, + "PipelineBuildSynthCdkBuildProject6BEFA8E6": { + "Type": "AWS::CodeBuild::Project", + "Properties": { + "Artifacts": { + "Type": "CODEPIPELINE" + }, + "Environment": { + "ComputeType": "BUILD_GENERAL1_SMALL", + "Image": "aws/codebuild/standard:5.0", + "ImagePullCredentialsType": "CODEBUILD", + "PrivilegedMode": false, + "Type": "LINUX_CONTAINER" + }, + "ServiceRole": { + "Fn::GetAtt": [ + "PipelineBuildSynthCdkBuildProjectRole231EEA2A", + "Arn" + ] + }, + "Source": { + "BuildSpec": "{\n \"version\": \"0.2\",\n \"phases\": {\n \"build\": {\n \"commands\": [\n \"npm ci\",\n \"npm run build\",\n \"npx cdk synth\"\n ]\n }\n },\n \"artifacts\": {\n \"base-directory\": \"cdk.out\",\n \"files\": \"**/*\"\n }\n}", + "Type": "CODEPIPELINE" + }, + "Cache": { + "Type": "NO_CACHE" + }, + "Description": "Pipeline step PipelineStack/Pipeline/Build/Synth", + "EncryptionKey": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + } + } + }, + "PipelineCodeBuildActionRole226DB0CB": { + "Type": "AWS::IAM::Role", + "Properties": { + "AssumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Condition": { + "Bool": { + "aws:ViaAWSService": "codepipeline.amazonaws.com" + } + }, + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + } + } + ], + "Version": "2012-10-17" + } + } + }, + "PipelineCodeBuildActionRoleDefaultPolicy1D62A6FE": { + "Type": "AWS::IAM::Policy", + "Properties": { + "PolicyDocument": { + "Statement": [ + { + "Action": [ + "codebuild:BatchGetBuilds", + "codebuild:StartBuild", + "codebuild:StopBuild" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::GetAtt": [ + "PipelineBuildSynthCdkBuildProject6BEFA8E6", + "Arn" + ] + }, + { + "Fn::GetAtt": [ + "PipelineUpdatePipelineSelfMutationDAA41400", + "Arn" + ] + } + ] + } + ], + "Version": "2012-10-17" + }, + "PolicyName": "PipelineCodeBuildActionRoleDefaultPolicy1D62A6FE", + "Roles": [ + { + "Ref": "PipelineCodeBuildActionRole226DB0CB" + } + ] + } + }, + "PipelineUpdatePipelineSelfMutationRole57E559E8": { + "Type": "AWS::IAM::Role", + "Properties": { + "AssumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "codebuild.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + } + } + }, + "PipelineUpdatePipelineSelfMutationRoleDefaultPolicyA225DA4E": { + "Type": "AWS::IAM::Policy", + "Properties": { + "PolicyDocument": { + "Statement": [ + { + "Action": [ + "logs:CreateLogGroup", + "logs:CreateLogStream", + "logs:PutLogEvents" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/codebuild/", + { + "Ref": "PipelineUpdatePipelineSelfMutationDAA41400" + }, + ":*" + ] + ] + }, + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/codebuild/", + { + "Ref": "PipelineUpdatePipelineSelfMutationDAA41400" + } + ] + ] + } + ] + }, + { + "Action": [ + "codebuild:BatchPutCodeCoverages", + "codebuild:BatchPutTestCases", + "codebuild:CreateReport", + "codebuild:CreateReportGroup", + "codebuild:UpdateReport" + ], + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":codebuild:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":report-group/", + { + "Ref": "PipelineUpdatePipelineSelfMutationDAA41400" + }, + "-*" + ] + ] + } + }, + { + "Action": "sts:AssumeRole", + "Condition": { + "ForAnyValue:StringEquals": { + "iam:ResourceTag/aws-cdk:bootstrap-role": [ + "image-publishing", + "file-publishing", + "deploy" + ] + } + }, + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:*:iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/*" + ] + ] + } + }, + { + "Action": [ + "cloudformation:DescribeStacks", + "s3:ListBucket" + ], + "Effect": "Allow", + "Resource": "*" + }, + { + "Action": [ + "s3:GetBucket*", + "s3:GetObject*", + "s3:List*" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "kms:Decrypt", + "kms:DescribeKey", + "kms:Encrypt", + "kms:GenerateDataKey*", + "kms:ReEncrypt*" + ], + "Effect": "Allow", + "Resource": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + } + } + ], + "Version": "2012-10-17" + }, + "PolicyName": "PipelineUpdatePipelineSelfMutationRoleDefaultPolicyA225DA4E", + "Roles": [ + { + "Ref": "PipelineUpdatePipelineSelfMutationRole57E559E8" + } + ] + } + }, + "PipelineUpdatePipelineSelfMutationDAA41400": { + "Type": "AWS::CodeBuild::Project", + "Properties": { + "Artifacts": { + "Type": "CODEPIPELINE" + }, + "Environment": { + "ComputeType": "BUILD_GENERAL1_SMALL", + "Image": "aws/codebuild/standard:5.0", + "ImagePullCredentialsType": "CODEBUILD", + "PrivilegedMode": false, + "Type": "LINUX_CONTAINER" + }, + "ServiceRole": { + "Fn::GetAtt": [ + "PipelineUpdatePipelineSelfMutationRole57E559E8", + "Arn" + ] + }, + "Source": { + "BuildSpec": "{\n \"version\": \"0.2\",\n \"phases\": {\n \"install\": {\n \"commands\": [\n \"npm install -g aws-cdk@1\"\n ]\n },\n \"build\": {\n \"commands\": [\n \"cdk -a . deploy PipelineStack --require-approval=never --verbose\"\n ]\n }\n }\n}", + "Type": "CODEPIPELINE" + }, + "Cache": { + "Type": "NO_CACHE" + }, + "Description": "Pipeline step PipelineStack/Pipeline/UpdatePipeline/SelfMutate", + "EncryptionKey": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + } + } + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/PipelineStackBetaStack1E6541489.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/PipelineStackBetaStack1E6541489.assets.json new file mode 100644 index 0000000000000..f199f50526e58 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/PipelineStackBetaStack1E6541489.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "91031b26c04588c38a59e3481d308182b5244c5f5a3af3ee05566e2f4f70ce65": { + "source": { + "path": "PipelineStackBetaStack1E6541489.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "91031b26c04588c38a59e3481d308182b5244c5f5a3af3ee05566e2f4f70ce65.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/PipelineStackBetaStack1E6541489.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/PipelineStackBetaStack1E6541489.template.json new file mode 100644 index 0000000000000..c1339d0126ee2 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/PipelineStackBetaStack1E6541489.template.json @@ -0,0 +1,56 @@ +{ + "Resources": { + "Queue4A7E3555": { + "Type": "AWS::SQS::Queue", + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + } + }, + "Outputs": { + "ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E": { + "Value": { + "Fn::GetAtt": [ + "Queue4A7E3555", + "Arn" + ] + }, + "Export": { + "Name": "Beta-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + } + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/PipelineStackBetaStack2C79AD00A.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/PipelineStackBetaStack2C79AD00A.assets.json new file mode 100644 index 0000000000000..de61f2f0d61b8 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/PipelineStackBetaStack2C79AD00A.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "e3aa38ca82b00b776ad3834e9ee862d2e529d91c0f0b12fad846884e1e600326": { + "source": { + "path": "PipelineStackBetaStack2C79AD00A.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "e3aa38ca82b00b776ad3834e9ee862d2e529d91c0f0b12fad846884e1e600326.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/PipelineStackBetaStack2C79AD00A.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/PipelineStackBetaStack2C79AD00A.template.json new file mode 100644 index 0000000000000..f7390e702aa6d --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/PipelineStackBetaStack2C79AD00A.template.json @@ -0,0 +1,51 @@ +{ + "Resources": { + "OtherQueue60B686DC": { + "Type": "AWS::SQS::Queue", + "Properties": { + "RedrivePolicy": { + "deadLetterTargetArn": { + "Fn::ImportValue": "Beta-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + }, + "maxReceiveCount": 5 + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/cdk.out b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/cdk.out new file mode 100644 index 0000000000000..d8b441d447f8a --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/cdk.out @@ -0,0 +1 @@ +{"version":"29.0.0"} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/manifest.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/manifest.json new file mode 100644 index 0000000000000..44178c8276b5a --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Beta/manifest.json @@ -0,0 +1,120 @@ +{ + "version": "29.0.0", + "artifacts": { + "PipelineStackBetaStack1E6541489.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStackBetaStack1E6541489.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStackBetaStack1E6541489": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStackBetaStack1E6541489.template.json", + "validateOnSynth": true, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/91031b26c04588c38a59e3481d308182b5244c5f5a3af3ee05566e2f4f70ce65.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStackBetaStack1E6541489.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + }, + "stackName": "Beta-Stack1" + }, + "dependencies": [ + "PipelineStackBetaStack1E6541489.assets" + ], + "metadata": { + "/PipelineStack/Beta/Stack1/Queue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "Queue4A7E3555" + } + ], + "/PipelineStack/Beta/Stack1/Exports/Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}": [ + { + "type": "aws:cdk:logicalId", + "data": "ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + } + ], + "/PipelineStack/Beta/Stack1/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/Beta/Stack1/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack/Beta/Stack1" + }, + "PipelineStackBetaStack2C79AD00A.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStackBetaStack2C79AD00A.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStackBetaStack2C79AD00A": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStackBetaStack2C79AD00A.template.json", + "validateOnSynth": true, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/e3aa38ca82b00b776ad3834e9ee862d2e529d91c0f0b12fad846884e1e600326.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStackBetaStack2C79AD00A.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + }, + "stackName": "Beta-Stack2" + }, + "dependencies": [ + "PipelineStackBetaStack1E6541489", + "PipelineStackBetaStack2C79AD00A.assets" + ], + "metadata": { + "/PipelineStack/Beta/Stack2/OtherQueue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "OtherQueue60B686DC" + } + ], + "/PipelineStack/Beta/Stack2/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/Beta/Stack2/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack/Beta/Stack2" + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/PipelineStackProd1Stack14013D698.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/PipelineStackProd1Stack14013D698.assets.json new file mode 100644 index 0000000000000..b7ffa2a662eb3 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/PipelineStackProd1Stack14013D698.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "774f0c3cec814003a4da7d6cab73aec82952a0cb52a221b3f94fae483d9922a3": { + "source": { + "path": "PipelineStackProd1Stack14013D698.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "774f0c3cec814003a4da7d6cab73aec82952a0cb52a221b3f94fae483d9922a3.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/PipelineStackProd1Stack14013D698.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/PipelineStackProd1Stack14013D698.template.json new file mode 100644 index 0000000000000..b46a5cc4fbb7d --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/PipelineStackProd1Stack14013D698.template.json @@ -0,0 +1,56 @@ +{ + "Resources": { + "Queue4A7E3555": { + "Type": "AWS::SQS::Queue", + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + } + }, + "Outputs": { + "ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E": { + "Value": { + "Fn::GetAtt": [ + "Queue4A7E3555", + "Arn" + ] + }, + "Export": { + "Name": "Prod1-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + } + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/PipelineStackProd1Stack2F0681AFF.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/PipelineStackProd1Stack2F0681AFF.assets.json new file mode 100644 index 0000000000000..7726d630cea66 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/PipelineStackProd1Stack2F0681AFF.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "c1cb4eebe68ea920a89e618efa29c36ecc1aa0c6f6ef6b65559efe9c0bba4059": { + "source": { + "path": "PipelineStackProd1Stack2F0681AFF.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "c1cb4eebe68ea920a89e618efa29c36ecc1aa0c6f6ef6b65559efe9c0bba4059.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/PipelineStackProd1Stack2F0681AFF.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/PipelineStackProd1Stack2F0681AFF.template.json new file mode 100644 index 0000000000000..fcabd32211080 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/PipelineStackProd1Stack2F0681AFF.template.json @@ -0,0 +1,51 @@ +{ + "Resources": { + "OtherQueue60B686DC": { + "Type": "AWS::SQS::Queue", + "Properties": { + "RedrivePolicy": { + "deadLetterTargetArn": { + "Fn::ImportValue": "Prod1-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + }, + "maxReceiveCount": 5 + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/cdk.out b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/cdk.out new file mode 100644 index 0000000000000..d8b441d447f8a --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/cdk.out @@ -0,0 +1 @@ +{"version":"29.0.0"} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/manifest.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/manifest.json new file mode 100644 index 0000000000000..84e886b05f023 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod1/manifest.json @@ -0,0 +1,120 @@ +{ + "version": "29.0.0", + "artifacts": { + "PipelineStackProd1Stack14013D698.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStackProd1Stack14013D698.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStackProd1Stack14013D698": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStackProd1Stack14013D698.template.json", + "validateOnSynth": true, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/774f0c3cec814003a4da7d6cab73aec82952a0cb52a221b3f94fae483d9922a3.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStackProd1Stack14013D698.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + }, + "stackName": "Prod1-Stack1" + }, + "dependencies": [ + "PipelineStackProd1Stack14013D698.assets" + ], + "metadata": { + "/PipelineStack/Prod1/Stack1/Queue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "Queue4A7E3555" + } + ], + "/PipelineStack/Prod1/Stack1/Exports/Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}": [ + { + "type": "aws:cdk:logicalId", + "data": "ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + } + ], + "/PipelineStack/Prod1/Stack1/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/Prod1/Stack1/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack/Prod1/Stack1" + }, + "PipelineStackProd1Stack2F0681AFF.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStackProd1Stack2F0681AFF.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStackProd1Stack2F0681AFF": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStackProd1Stack2F0681AFF.template.json", + "validateOnSynth": true, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/c1cb4eebe68ea920a89e618efa29c36ecc1aa0c6f6ef6b65559efe9c0bba4059.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStackProd1Stack2F0681AFF.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + }, + "stackName": "Prod1-Stack2" + }, + "dependencies": [ + "PipelineStackProd1Stack14013D698", + "PipelineStackProd1Stack2F0681AFF.assets" + ], + "metadata": { + "/PipelineStack/Prod1/Stack2/OtherQueue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "OtherQueue60B686DC" + } + ], + "/PipelineStack/Prod1/Stack2/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/Prod1/Stack2/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack/Prod1/Stack2" + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/PipelineStackProd2Stack1FD464162.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/PipelineStackProd2Stack1FD464162.assets.json new file mode 100644 index 0000000000000..3c89b6ce514f5 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/PipelineStackProd2Stack1FD464162.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "a595899a57366f015e986ac46c3da09fac75670ea0f4719de8defc67d731fa68": { + "source": { + "path": "PipelineStackProd2Stack1FD464162.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "a595899a57366f015e986ac46c3da09fac75670ea0f4719de8defc67d731fa68.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/PipelineStackProd2Stack1FD464162.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/PipelineStackProd2Stack1FD464162.template.json new file mode 100644 index 0000000000000..302ccbd07207e --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/PipelineStackProd2Stack1FD464162.template.json @@ -0,0 +1,56 @@ +{ + "Resources": { + "Queue4A7E3555": { + "Type": "AWS::SQS::Queue", + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + } + }, + "Outputs": { + "ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E": { + "Value": { + "Fn::GetAtt": [ + "Queue4A7E3555", + "Arn" + ] + }, + "Export": { + "Name": "Prod2-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + } + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/PipelineStackProd2Stack2176123EB.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/PipelineStackProd2Stack2176123EB.assets.json new file mode 100644 index 0000000000000..d53df689d7a91 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/PipelineStackProd2Stack2176123EB.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "364ee9a72c6c371a00c6e41438695af070848a2d625a4c953bfc4666e7ad5ae9": { + "source": { + "path": "PipelineStackProd2Stack2176123EB.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "364ee9a72c6c371a00c6e41438695af070848a2d625a4c953bfc4666e7ad5ae9.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/PipelineStackProd2Stack2176123EB.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/PipelineStackProd2Stack2176123EB.template.json new file mode 100644 index 0000000000000..933decc98d696 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/PipelineStackProd2Stack2176123EB.template.json @@ -0,0 +1,51 @@ +{ + "Resources": { + "OtherQueue60B686DC": { + "Type": "AWS::SQS::Queue", + "Properties": { + "RedrivePolicy": { + "deadLetterTargetArn": { + "Fn::ImportValue": "Prod2-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + }, + "maxReceiveCount": 5 + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/cdk.out b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/cdk.out new file mode 100644 index 0000000000000..d8b441d447f8a --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/cdk.out @@ -0,0 +1 @@ +{"version":"29.0.0"} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/manifest.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/manifest.json new file mode 100644 index 0000000000000..793401e5b7f4b --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod2/manifest.json @@ -0,0 +1,120 @@ +{ + "version": "29.0.0", + "artifacts": { + "PipelineStackProd2Stack1FD464162.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStackProd2Stack1FD464162.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStackProd2Stack1FD464162": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStackProd2Stack1FD464162.template.json", + "validateOnSynth": true, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/a595899a57366f015e986ac46c3da09fac75670ea0f4719de8defc67d731fa68.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStackProd2Stack1FD464162.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + }, + "stackName": "Prod2-Stack1" + }, + "dependencies": [ + "PipelineStackProd2Stack1FD464162.assets" + ], + "metadata": { + "/PipelineStack/Prod2/Stack1/Queue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "Queue4A7E3555" + } + ], + "/PipelineStack/Prod2/Stack1/Exports/Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}": [ + { + "type": "aws:cdk:logicalId", + "data": "ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + } + ], + "/PipelineStack/Prod2/Stack1/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/Prod2/Stack1/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack/Prod2/Stack1" + }, + "PipelineStackProd2Stack2176123EB.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStackProd2Stack2176123EB.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStackProd2Stack2176123EB": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStackProd2Stack2176123EB.template.json", + "validateOnSynth": true, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/364ee9a72c6c371a00c6e41438695af070848a2d625a4c953bfc4666e7ad5ae9.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStackProd2Stack2176123EB.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + }, + "stackName": "Prod2-Stack2" + }, + "dependencies": [ + "PipelineStackProd2Stack1FD464162", + "PipelineStackProd2Stack2176123EB.assets" + ], + "metadata": { + "/PipelineStack/Prod2/Stack2/OtherQueue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "OtherQueue60B686DC" + } + ], + "/PipelineStack/Prod2/Stack2/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/Prod2/Stack2/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack/Prod2/Stack2" + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/PipelineStackProd3Stack1795F3D43.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/PipelineStackProd3Stack1795F3D43.assets.json new file mode 100644 index 0000000000000..c55b572802965 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/PipelineStackProd3Stack1795F3D43.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "e8c78794529aa32b354a78b7b979165b0cadd9d113a37f537d083f946c0e7bff": { + "source": { + "path": "PipelineStackProd3Stack1795F3D43.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "e8c78794529aa32b354a78b7b979165b0cadd9d113a37f537d083f946c0e7bff.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/PipelineStackProd3Stack1795F3D43.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/PipelineStackProd3Stack1795F3D43.template.json new file mode 100644 index 0000000000000..001e76f16f49a --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/PipelineStackProd3Stack1795F3D43.template.json @@ -0,0 +1,56 @@ +{ + "Resources": { + "Queue4A7E3555": { + "Type": "AWS::SQS::Queue", + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + } + }, + "Outputs": { + "ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E": { + "Value": { + "Fn::GetAtt": [ + "Queue4A7E3555", + "Arn" + ] + }, + "Export": { + "Name": "Prod3-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + } + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/PipelineStackProd3Stack2DFBBA0B2.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/PipelineStackProd3Stack2DFBBA0B2.assets.json new file mode 100644 index 0000000000000..d2499d3c6f9ef --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/PipelineStackProd3Stack2DFBBA0B2.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "9fee5ad34559e603d3fc184456935445ea09549b147d2cbc2acd8cf6b916dd99": { + "source": { + "path": "PipelineStackProd3Stack2DFBBA0B2.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "9fee5ad34559e603d3fc184456935445ea09549b147d2cbc2acd8cf6b916dd99.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/PipelineStackProd3Stack2DFBBA0B2.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/PipelineStackProd3Stack2DFBBA0B2.template.json new file mode 100644 index 0000000000000..dc2e4203973f5 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/PipelineStackProd3Stack2DFBBA0B2.template.json @@ -0,0 +1,51 @@ +{ + "Resources": { + "OtherQueue60B686DC": { + "Type": "AWS::SQS::Queue", + "Properties": { + "RedrivePolicy": { + "deadLetterTargetArn": { + "Fn::ImportValue": "Prod3-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + }, + "maxReceiveCount": 5 + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/cdk.out b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/cdk.out new file mode 100644 index 0000000000000..d8b441d447f8a --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/cdk.out @@ -0,0 +1 @@ +{"version":"29.0.0"} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/manifest.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/manifest.json new file mode 100644 index 0000000000000..dab78742ac8f3 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod3/manifest.json @@ -0,0 +1,120 @@ +{ + "version": "29.0.0", + "artifacts": { + "PipelineStackProd3Stack1795F3D43.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStackProd3Stack1795F3D43.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStackProd3Stack1795F3D43": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStackProd3Stack1795F3D43.template.json", + "validateOnSynth": true, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/e8c78794529aa32b354a78b7b979165b0cadd9d113a37f537d083f946c0e7bff.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStackProd3Stack1795F3D43.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + }, + "stackName": "Prod3-Stack1" + }, + "dependencies": [ + "PipelineStackProd3Stack1795F3D43.assets" + ], + "metadata": { + "/PipelineStack/Prod3/Stack1/Queue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "Queue4A7E3555" + } + ], + "/PipelineStack/Prod3/Stack1/Exports/Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}": [ + { + "type": "aws:cdk:logicalId", + "data": "ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + } + ], + "/PipelineStack/Prod3/Stack1/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/Prod3/Stack1/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack/Prod3/Stack1" + }, + "PipelineStackProd3Stack2DFBBA0B2.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStackProd3Stack2DFBBA0B2.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStackProd3Stack2DFBBA0B2": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStackProd3Stack2DFBBA0B2.template.json", + "validateOnSynth": true, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/9fee5ad34559e603d3fc184456935445ea09549b147d2cbc2acd8cf6b916dd99.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStackProd3Stack2DFBBA0B2.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + }, + "stackName": "Prod3-Stack2" + }, + "dependencies": [ + "PipelineStackProd3Stack1795F3D43", + "PipelineStackProd3Stack2DFBBA0B2.assets" + ], + "metadata": { + "/PipelineStack/Prod3/Stack2/OtherQueue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "OtherQueue60B686DC" + } + ], + "/PipelineStack/Prod3/Stack2/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/Prod3/Stack2/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack/Prod3/Stack2" + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/PipelineStackProd4Stack118F74ADB.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/PipelineStackProd4Stack118F74ADB.assets.json new file mode 100644 index 0000000000000..450141f8baf32 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/PipelineStackProd4Stack118F74ADB.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "7e0ecf5ec563ed47798cfb17d4c3ce0e6c710c075fc53bf8cd15d8fb9a210f78": { + "source": { + "path": "PipelineStackProd4Stack118F74ADB.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "7e0ecf5ec563ed47798cfb17d4c3ce0e6c710c075fc53bf8cd15d8fb9a210f78.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/PipelineStackProd4Stack118F74ADB.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/PipelineStackProd4Stack118F74ADB.template.json new file mode 100644 index 0000000000000..2b548d4d93efd --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/PipelineStackProd4Stack118F74ADB.template.json @@ -0,0 +1,56 @@ +{ + "Resources": { + "Queue4A7E3555": { + "Type": "AWS::SQS::Queue", + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + } + }, + "Outputs": { + "ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E": { + "Value": { + "Fn::GetAtt": [ + "Queue4A7E3555", + "Arn" + ] + }, + "Export": { + "Name": "Prod4-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + } + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/PipelineStackProd4Stack2E2CB4ED3.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/PipelineStackProd4Stack2E2CB4ED3.assets.json new file mode 100644 index 0000000000000..44abc221b7ad2 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/PipelineStackProd4Stack2E2CB4ED3.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "a9cddd81a8937cbadd9bf93c6fe07766501a7c137605bb09e6cfa322b2eb09fd": { + "source": { + "path": "PipelineStackProd4Stack2E2CB4ED3.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "a9cddd81a8937cbadd9bf93c6fe07766501a7c137605bb09e6cfa322b2eb09fd.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/PipelineStackProd4Stack2E2CB4ED3.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/PipelineStackProd4Stack2E2CB4ED3.template.json new file mode 100644 index 0000000000000..631819bed2136 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/PipelineStackProd4Stack2E2CB4ED3.template.json @@ -0,0 +1,51 @@ +{ + "Resources": { + "OtherQueue60B686DC": { + "Type": "AWS::SQS::Queue", + "Properties": { + "RedrivePolicy": { + "deadLetterTargetArn": { + "Fn::ImportValue": "Prod4-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + }, + "maxReceiveCount": 5 + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/cdk.out b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/cdk.out new file mode 100644 index 0000000000000..d8b441d447f8a --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/cdk.out @@ -0,0 +1 @@ +{"version":"29.0.0"} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/manifest.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/manifest.json new file mode 100644 index 0000000000000..9c756ab77fd23 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod4/manifest.json @@ -0,0 +1,120 @@ +{ + "version": "29.0.0", + "artifacts": { + "PipelineStackProd4Stack118F74ADB.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStackProd4Stack118F74ADB.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStackProd4Stack118F74ADB": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStackProd4Stack118F74ADB.template.json", + "validateOnSynth": true, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/7e0ecf5ec563ed47798cfb17d4c3ce0e6c710c075fc53bf8cd15d8fb9a210f78.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStackProd4Stack118F74ADB.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + }, + "stackName": "Prod4-Stack1" + }, + "dependencies": [ + "PipelineStackProd4Stack118F74ADB.assets" + ], + "metadata": { + "/PipelineStack/Prod4/Stack1/Queue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "Queue4A7E3555" + } + ], + "/PipelineStack/Prod4/Stack1/Exports/Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}": [ + { + "type": "aws:cdk:logicalId", + "data": "ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + } + ], + "/PipelineStack/Prod4/Stack1/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/Prod4/Stack1/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack/Prod4/Stack1" + }, + "PipelineStackProd4Stack2E2CB4ED3.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStackProd4Stack2E2CB4ED3.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStackProd4Stack2E2CB4ED3": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStackProd4Stack2E2CB4ED3.template.json", + "validateOnSynth": true, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/a9cddd81a8937cbadd9bf93c6fe07766501a7c137605bb09e6cfa322b2eb09fd.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStackProd4Stack2E2CB4ED3.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + }, + "stackName": "Prod4-Stack2" + }, + "dependencies": [ + "PipelineStackProd4Stack118F74ADB", + "PipelineStackProd4Stack2E2CB4ED3.assets" + ], + "metadata": { + "/PipelineStack/Prod4/Stack2/OtherQueue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "OtherQueue60B686DC" + } + ], + "/PipelineStack/Prod4/Stack2/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/Prod4/Stack2/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack/Prod4/Stack2" + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/PipelineStackProd5Stack1E7E4E4C6.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/PipelineStackProd5Stack1E7E4E4C6.assets.json new file mode 100644 index 0000000000000..c44f6ea2b183b --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/PipelineStackProd5Stack1E7E4E4C6.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "1e0089d5c027ddec49745fce045925aff9342fbffdf989e4ae5263fd87ee50f7": { + "source": { + "path": "PipelineStackProd5Stack1E7E4E4C6.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "1e0089d5c027ddec49745fce045925aff9342fbffdf989e4ae5263fd87ee50f7.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/PipelineStackProd5Stack1E7E4E4C6.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/PipelineStackProd5Stack1E7E4E4C6.template.json new file mode 100644 index 0000000000000..658620fcb843a --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/PipelineStackProd5Stack1E7E4E4C6.template.json @@ -0,0 +1,56 @@ +{ + "Resources": { + "Queue4A7E3555": { + "Type": "AWS::SQS::Queue", + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + } + }, + "Outputs": { + "ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E": { + "Value": { + "Fn::GetAtt": [ + "Queue4A7E3555", + "Arn" + ] + }, + "Export": { + "Name": "Prod5-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + } + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/PipelineStackProd5Stack2C39BEE5B.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/PipelineStackProd5Stack2C39BEE5B.assets.json new file mode 100644 index 0000000000000..158c0083e7147 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/PipelineStackProd5Stack2C39BEE5B.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "48a94145722a5a14816cb87dce62fadba53a03b2c18e0fdfb5107ffabd5d7cd8": { + "source": { + "path": "PipelineStackProd5Stack2C39BEE5B.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "48a94145722a5a14816cb87dce62fadba53a03b2c18e0fdfb5107ffabd5d7cd8.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/PipelineStackProd5Stack2C39BEE5B.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/PipelineStackProd5Stack2C39BEE5B.template.json new file mode 100644 index 0000000000000..67e0c24ee96fb --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/PipelineStackProd5Stack2C39BEE5B.template.json @@ -0,0 +1,51 @@ +{ + "Resources": { + "OtherQueue60B686DC": { + "Type": "AWS::SQS::Queue", + "Properties": { + "RedrivePolicy": { + "deadLetterTargetArn": { + "Fn::ImportValue": "Prod5-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + }, + "maxReceiveCount": 5 + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/cdk.out b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/cdk.out new file mode 100644 index 0000000000000..d8b441d447f8a --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/cdk.out @@ -0,0 +1 @@ +{"version":"29.0.0"} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/manifest.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/manifest.json new file mode 100644 index 0000000000000..fe561a6512340 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod5/manifest.json @@ -0,0 +1,120 @@ +{ + "version": "29.0.0", + "artifacts": { + "PipelineStackProd5Stack1E7E4E4C6.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStackProd5Stack1E7E4E4C6.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStackProd5Stack1E7E4E4C6": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStackProd5Stack1E7E4E4C6.template.json", + "validateOnSynth": true, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/1e0089d5c027ddec49745fce045925aff9342fbffdf989e4ae5263fd87ee50f7.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStackProd5Stack1E7E4E4C6.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + }, + "stackName": "Prod5-Stack1" + }, + "dependencies": [ + "PipelineStackProd5Stack1E7E4E4C6.assets" + ], + "metadata": { + "/PipelineStack/Prod5/Stack1/Queue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "Queue4A7E3555" + } + ], + "/PipelineStack/Prod5/Stack1/Exports/Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}": [ + { + "type": "aws:cdk:logicalId", + "data": "ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + } + ], + "/PipelineStack/Prod5/Stack1/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/Prod5/Stack1/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack/Prod5/Stack1" + }, + "PipelineStackProd5Stack2C39BEE5B.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStackProd5Stack2C39BEE5B.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStackProd5Stack2C39BEE5B": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStackProd5Stack2C39BEE5B.template.json", + "validateOnSynth": true, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/48a94145722a5a14816cb87dce62fadba53a03b2c18e0fdfb5107ffabd5d7cd8.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStackProd5Stack2C39BEE5B.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + }, + "stackName": "Prod5-Stack2" + }, + "dependencies": [ + "PipelineStackProd5Stack1E7E4E4C6", + "PipelineStackProd5Stack2C39BEE5B.assets" + ], + "metadata": { + "/PipelineStack/Prod5/Stack2/OtherQueue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "OtherQueue60B686DC" + } + ], + "/PipelineStack/Prod5/Stack2/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/Prod5/Stack2/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack/Prod5/Stack2" + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/PipelineStackProd6Stack1E7C34314.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/PipelineStackProd6Stack1E7C34314.assets.json new file mode 100644 index 0000000000000..880e81b8852d1 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/PipelineStackProd6Stack1E7C34314.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "26d311d19506235a52c5d093cf5a8360110af6a2b713beda66b33ba3ee5bd813": { + "source": { + "path": "PipelineStackProd6Stack1E7C34314.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "26d311d19506235a52c5d093cf5a8360110af6a2b713beda66b33ba3ee5bd813.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/PipelineStackProd6Stack1E7C34314.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/PipelineStackProd6Stack1E7C34314.template.json new file mode 100644 index 0000000000000..7ac93ccb63c33 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/PipelineStackProd6Stack1E7C34314.template.json @@ -0,0 +1,56 @@ +{ + "Resources": { + "Queue4A7E3555": { + "Type": "AWS::SQS::Queue", + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + } + }, + "Outputs": { + "ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E": { + "Value": { + "Fn::GetAtt": [ + "Queue4A7E3555", + "Arn" + ] + }, + "Export": { + "Name": "Prod6-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + } + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/PipelineStackProd6Stack2BED1BBCE.assets.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/PipelineStackProd6Stack2BED1BBCE.assets.json new file mode 100644 index 0000000000000..193e0ebce2115 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/PipelineStackProd6Stack2BED1BBCE.assets.json @@ -0,0 +1,19 @@ +{ + "version": "29.0.0", + "files": { + "8f3e16ae3f29a4a50d4ef13026a3bc879e039d80e9fffdefe19d40349ec6bb30": { + "source": { + "path": "PipelineStackProd6Stack2BED1BBCE.template.json", + "packaging": "file" + }, + "destinations": { + "current_account-current_region": { + "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", + "objectKey": "8f3e16ae3f29a4a50d4ef13026a3bc879e039d80e9fffdefe19d40349ec6bb30.json", + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/PipelineStackProd6Stack2BED1BBCE.template.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/PipelineStackProd6Stack2BED1BBCE.template.json new file mode 100644 index 0000000000000..dd780ed92f925 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/PipelineStackProd6Stack2BED1BBCE.template.json @@ -0,0 +1,51 @@ +{ + "Resources": { + "OtherQueue60B686DC": { + "Type": "AWS::SQS::Queue", + "Properties": { + "RedrivePolicy": { + "deadLetterTargetArn": { + "Fn::ImportValue": "Prod6-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + }, + "maxReceiveCount": 5 + } + }, + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/cdk.out b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/cdk.out new file mode 100644 index 0000000000000..d8b441d447f8a --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/cdk.out @@ -0,0 +1 @@ +{"version":"29.0.0"} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/manifest.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/manifest.json new file mode 100644 index 0000000000000..cb703434ad45b --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/assembly-PipelineStack-Prod6/manifest.json @@ -0,0 +1,120 @@ +{ + "version": "29.0.0", + "artifacts": { + "PipelineStackProd6Stack1E7C34314.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStackProd6Stack1E7C34314.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStackProd6Stack1E7C34314": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStackProd6Stack1E7C34314.template.json", + "validateOnSynth": true, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/26d311d19506235a52c5d093cf5a8360110af6a2b713beda66b33ba3ee5bd813.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStackProd6Stack1E7C34314.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + }, + "stackName": "Prod6-Stack1" + }, + "dependencies": [ + "PipelineStackProd6Stack1E7C34314.assets" + ], + "metadata": { + "/PipelineStack/Prod6/Stack1/Queue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "Queue4A7E3555" + } + ], + "/PipelineStack/Prod6/Stack1/Exports/Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}": [ + { + "type": "aws:cdk:logicalId", + "data": "ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + } + ], + "/PipelineStack/Prod6/Stack1/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/Prod6/Stack1/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack/Prod6/Stack1" + }, + "PipelineStackProd6Stack2BED1BBCE.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStackProd6Stack2BED1BBCE.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStackProd6Stack2BED1BBCE": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStackProd6Stack2BED1BBCE.template.json", + "validateOnSynth": true, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/8f3e16ae3f29a4a50d4ef13026a3bc879e039d80e9fffdefe19d40349ec6bb30.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStackProd6Stack2BED1BBCE.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + }, + "stackName": "Prod6-Stack2" + }, + "dependencies": [ + "PipelineStackProd6Stack1E7C34314", + "PipelineStackProd6Stack2BED1BBCE.assets" + ], + "metadata": { + "/PipelineStack/Prod6/Stack2/OtherQueue/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "OtherQueue60B686DC" + } + ], + "/PipelineStack/Prod6/Stack2/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/Prod6/Stack2/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack/Prod6/Stack2" + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/cdk.out b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/cdk.out new file mode 100644 index 0000000000000..d8b441d447f8a --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/cdk.out @@ -0,0 +1 @@ +{"version":"29.0.0"} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/integ.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/integ.json new file mode 100644 index 0000000000000..9c049ebb503d9 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/integ.json @@ -0,0 +1,12 @@ +{ + "version": "29.0.0", + "testCases": { + "LambdaTest/DefaultTest": { + "stacks": [ + "PipelineStack" + ], + "assertionStack": "LambdaTest/DefaultTest/DeployAssert", + "assertionStackName": "LambdaTestDefaultTestDeployAssert1AF2B360" + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/manifest.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/manifest.json new file mode 100644 index 0000000000000..ba995ae0a7667 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/manifest.json @@ -0,0 +1,250 @@ +{ + "version": "29.0.0", + "artifacts": { + "assembly-PipelineStack-Beta": { + "type": "cdk:cloud-assembly", + "properties": { + "directoryName": "assembly-PipelineStack-Beta", + "displayName": "PipelineStack/Beta" + } + }, + "assembly-PipelineStack-Prod1": { + "type": "cdk:cloud-assembly", + "properties": { + "directoryName": "assembly-PipelineStack-Prod1", + "displayName": "PipelineStack/Prod1" + } + }, + "assembly-PipelineStack-Prod2": { + "type": "cdk:cloud-assembly", + "properties": { + "directoryName": "assembly-PipelineStack-Prod2", + "displayName": "PipelineStack/Prod2" + } + }, + "assembly-PipelineStack-Prod3": { + "type": "cdk:cloud-assembly", + "properties": { + "directoryName": "assembly-PipelineStack-Prod3", + "displayName": "PipelineStack/Prod3" + } + }, + "assembly-PipelineStack-Prod4": { + "type": "cdk:cloud-assembly", + "properties": { + "directoryName": "assembly-PipelineStack-Prod4", + "displayName": "PipelineStack/Prod4" + } + }, + "assembly-PipelineStack-Prod5": { + "type": "cdk:cloud-assembly", + "properties": { + "directoryName": "assembly-PipelineStack-Prod5", + "displayName": "PipelineStack/Prod5" + } + }, + "assembly-PipelineStack-Prod6": { + "type": "cdk:cloud-assembly", + "properties": { + "directoryName": "assembly-PipelineStack-Prod6", + "displayName": "PipelineStack/Prod6" + } + }, + "PipelineStack.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "PipelineStack.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "PipelineStack": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "PipelineStack.template.json", + "validateOnSynth": false, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/c1bda7e2c84e91a5658af0b194a4c8918dead52ad783e29acbc3701149e73f45.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "PipelineStack.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "dependencies": [ + "PipelineStack.assets" + ], + "metadata": { + "/PipelineStack/Pipeline/Pipeline/ArtifactsBucketEncryptionKey/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineArtifactsBucketEncryptionKeyF5BF0670" + } + ], + "/PipelineStack/Pipeline/Pipeline/ArtifactsBucketEncryptionKeyAlias/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineArtifactsBucketEncryptionKeyAlias94A07392" + } + ], + "/PipelineStack/Pipeline/Pipeline/ArtifactsBucket/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineArtifactsBucketAEA9A052" + } + ], + "/PipelineStack/Pipeline/Pipeline/ArtifactsBucket/Policy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineArtifactsBucketPolicyF53CCC52" + } + ], + "/PipelineStack/Pipeline/Pipeline/Role/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineRoleB27FAA37" + } + ], + "/PipelineStack/Pipeline/Pipeline/Role/DefaultPolicy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineRoleDefaultPolicy7BDC1ABB" + } + ], + "/PipelineStack/Pipeline/Pipeline/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "Pipeline9850B417" + } + ], + "/PipelineStack/Pipeline/Pipeline/Source/tkglaser_cdk-pipelines-demo/WebhookResource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineSourcetkglasercdkpipelinesdemoWebhookResource54EE51BE" + } + ], + "/PipelineStack/Pipeline/Pipeline/Build/Synth/CdkBuildProject/Role/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineBuildSynthCdkBuildProjectRole231EEA2A" + } + ], + "/PipelineStack/Pipeline/Pipeline/Build/Synth/CdkBuildProject/Role/DefaultPolicy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineBuildSynthCdkBuildProjectRoleDefaultPolicyFB6C941C" + } + ], + "/PipelineStack/Pipeline/Pipeline/Build/Synth/CdkBuildProject/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineBuildSynthCdkBuildProject6BEFA8E6" + } + ], + "/PipelineStack/Pipeline/CodeBuildActionRole/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineCodeBuildActionRole226DB0CB" + } + ], + "/PipelineStack/Pipeline/CodeBuildActionRole/DefaultPolicy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineCodeBuildActionRoleDefaultPolicy1D62A6FE" + } + ], + "/PipelineStack/Pipeline/UpdatePipeline/SelfMutation/Role/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineUpdatePipelineSelfMutationRole57E559E8" + } + ], + "/PipelineStack/Pipeline/UpdatePipeline/SelfMutation/Role/DefaultPolicy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineUpdatePipelineSelfMutationRoleDefaultPolicyA225DA4E" + } + ], + "/PipelineStack/Pipeline/UpdatePipeline/SelfMutation/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineUpdatePipelineSelfMutationDAA41400" + } + ], + "/PipelineStack/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/PipelineStack/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "PipelineStack" + }, + "LambdaTestDefaultTestDeployAssert1AF2B360.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "LambdaTestDefaultTestDeployAssert1AF2B360.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "LambdaTestDefaultTestDeployAssert1AF2B360": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "LambdaTestDefaultTestDeployAssert1AF2B360.template.json", + "validateOnSynth": false, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "LambdaTestDefaultTestDeployAssert1AF2B360.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "dependencies": [ + "LambdaTestDefaultTestDeployAssert1AF2B360.assets" + ], + "metadata": { + "/LambdaTest/DefaultTest/DeployAssert/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/LambdaTest/DefaultTest/DeployAssert/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "LambdaTest/DefaultTest/DeployAssert" + }, + "Tree": { + "type": "cdk:tree", + "properties": { + "file": "tree.json" + } + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/tree.json b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/tree.json new file mode 100644 index 0000000000000..9498fef8dfd27 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.js.snapshot/tree.json @@ -0,0 +1,4200 @@ +{ + "version": "tree-0.1", + "tree": { + "id": "App", + "path": "", + "children": { + "PipelineStack": { + "id": "PipelineStack", + "path": "PipelineStack", + "children": { + "Pipeline": { + "id": "Pipeline", + "path": "PipelineStack/Pipeline", + "children": { + "Pipeline": { + "id": "Pipeline", + "path": "PipelineStack/Pipeline/Pipeline", + "children": { + "ArtifactsBucketEncryptionKey": { + "id": "ArtifactsBucketEncryptionKey", + "path": "PipelineStack/Pipeline/Pipeline/ArtifactsBucketEncryptionKey", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/Pipeline/ArtifactsBucketEncryptionKey/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::KMS::Key", + "aws:cdk:cloudformation:props": { + "keyPolicy": { + "Statement": [ + { + "Action": "kms:*", + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + }, + "Resource": "*" + }, + { + "Action": [ + "kms:Decrypt", + "kms:DescribeKey" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + "Resource": "*" + } + ], + "Version": "2012-10-17" + }, + "enableKeyRotation": true + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-kms.CfnKey", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-kms.Key", + "version": "0.0.0" + } + }, + "ArtifactsBucketEncryptionKeyAlias": { + "id": "ArtifactsBucketEncryptionKeyAlias", + "path": "PipelineStack/Pipeline/Pipeline/ArtifactsBucketEncryptionKeyAlias", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/Pipeline/ArtifactsBucketEncryptionKeyAlias/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::KMS::Alias", + "aws:cdk:cloudformation:props": { + "aliasName": "alias/codepipeline-pipelinestack-pipeline-e95eedaa", + "targetKeyId": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-kms.CfnAlias", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-kms.Alias", + "version": "0.0.0" + } + }, + "ArtifactsBucket": { + "id": "ArtifactsBucket", + "path": "PipelineStack/Pipeline/Pipeline/ArtifactsBucket", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/Pipeline/ArtifactsBucket/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::S3::Bucket", + "aws:cdk:cloudformation:props": { + "bucketEncryption": { + "serverSideEncryptionConfiguration": [ + { + "serverSideEncryptionByDefault": { + "sseAlgorithm": "aws:kms", + "kmsMasterKeyId": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + } + } + } + ] + }, + "publicAccessBlockConfiguration": { + "blockPublicAcls": true, + "blockPublicPolicy": true, + "ignorePublicAcls": true, + "restrictPublicBuckets": true + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-s3.CfnBucket", + "version": "0.0.0" + } + }, + "Policy": { + "id": "Policy", + "path": "PipelineStack/Pipeline/Pipeline/ArtifactsBucket/Policy", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/Pipeline/ArtifactsBucket/Policy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::S3::BucketPolicy", + "aws:cdk:cloudformation:props": { + "bucket": { + "Ref": "PipelineArtifactsBucketAEA9A052" + }, + "policyDocument": { + "Statement": [ + { + "Action": "s3:*", + "Condition": { + "Bool": { + "aws:SecureTransport": "false" + } + }, + "Effect": "Deny", + "Principal": { + "AWS": "*" + }, + "Resource": [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "s3:GetBucket*", + "s3:GetObject*", + "s3:List*" + ], + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + "Resource": [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + } + ], + "Version": "2012-10-17" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-s3.CfnBucketPolicy", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-s3.BucketPolicy", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-s3.Bucket", + "version": "0.0.0" + } + }, + "Role": { + "id": "Role", + "path": "PipelineStack/Pipeline/Pipeline/Role", + "children": { + "ImportRole": { + "id": "ImportRole", + "path": "PipelineStack/Pipeline/Pipeline/Role/ImportRole", + "constructInfo": { + "fqn": "@aws-cdk/core.Resource", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/Pipeline/Role/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Role", + "aws:cdk:cloudformation:props": { + "assumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "codepipeline.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.CfnRole", + "version": "0.0.0" + } + }, + "DefaultPolicy": { + "id": "DefaultPolicy", + "path": "PipelineStack/Pipeline/Pipeline/Role/DefaultPolicy", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/Pipeline/Role/DefaultPolicy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Policy", + "aws:cdk:cloudformation:props": { + "policyDocument": { + "Statement": [ + { + "Action": [ + "s3:Abort*", + "s3:DeleteObject*", + "s3:GetBucket*", + "s3:GetObject*", + "s3:List*", + "s3:PutObject", + "s3:PutObjectLegalHold", + "s3:PutObjectRetention", + "s3:PutObjectTagging", + "s3:PutObjectVersionTagging" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "kms:Decrypt", + "kms:DescribeKey", + "kms:Encrypt", + "kms:GenerateDataKey*", + "kms:ReEncrypt*" + ], + "Effect": "Allow", + "Resource": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + } + }, + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Resource": [ + { + "Fn::GetAtt": [ + "PipelineCodeBuildActionRole226DB0CB", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + ] + } + ], + "Version": "2012-10-17" + }, + "policyName": "PipelineRoleDefaultPolicy7BDC1ABB", + "roles": [ + { + "Ref": "PipelineRoleB27FAA37" + } + ] + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.CfnPolicy", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.Policy", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.Role", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/Pipeline/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::CodePipeline::Pipeline", + "aws:cdk:cloudformation:props": { + "roleArn": { + "Fn::GetAtt": [ + "PipelineRoleB27FAA37", + "Arn" + ] + }, + "stages": [ + { + "name": "Source", + "actions": [ + { + "name": "tkglaser_cdk-pipelines-demo", + "outputArtifacts": [ + { + "name": "tkglaser_cdk_pipelines_demo_Source" + } + ], + "actionTypeId": { + "category": "Source", + "version": "1", + "owner": "ThirdParty", + "provider": "GitHub" + }, + "configuration": { + "Owner": "tkglaser", + "Repo": "cdk-pipelines-demo", + "Branch": "main", + "OAuthToken": "{{resolve:secretsmanager:github-token:SecretString:::}}", + "PollForSourceChanges": false + }, + "runOrder": 1 + } + ] + }, + { + "name": "Build", + "actions": [ + { + "name": "Synth", + "inputArtifacts": [ + { + "name": "tkglaser_cdk_pipelines_demo_Source" + } + ], + "outputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Build", + "version": "1", + "owner": "AWS", + "provider": "CodeBuild" + }, + "configuration": { + "ProjectName": { + "Ref": "PipelineBuildSynthCdkBuildProject6BEFA8E6" + }, + "EnvironmentVariables": "[{\"name\":\"_PROJECT_CONFIG_HASH\",\"type\":\"PLAINTEXT\",\"value\":\"00ebacfb32b1bde8d3638577308e7b7144dfa3b0a58a83bc6ff38a3b1f26951c\"}]" + }, + "runOrder": 1, + "roleArn": { + "Fn::GetAtt": [ + "PipelineCodeBuildActionRole226DB0CB", + "Arn" + ] + } + } + ] + }, + { + "name": "UpdatePipeline", + "actions": [ + { + "name": "SelfMutate", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Build", + "version": "1", + "owner": "AWS", + "provider": "CodeBuild" + }, + "configuration": { + "ProjectName": { + "Ref": "PipelineUpdatePipelineSelfMutationDAA41400" + }, + "EnvironmentVariables": "[{\"name\":\"_PROJECT_CONFIG_HASH\",\"type\":\"PLAINTEXT\",\"value\":\"c0779bd925c3a7f19be75a4973c668d10d00ce3552b882c7d2ba3fa3cee6d976\"}]" + }, + "runOrder": 1, + "roleArn": { + "Fn::GetAtt": [ + "PipelineCodeBuildActionRole226DB0CB", + "Arn" + ] + } + } + ] + }, + { + "name": "Beta", + "actions": [ + { + "name": "Stack1.Prepare", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Beta-Stack1", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Beta/PipelineStackBetaStack1E6541489.template.json" + }, + "runOrder": 1, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Stack1.Deploy", + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Beta-Stack1", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "runOrder": 2, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Stack2.Prepare", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Beta-Stack2", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Beta/PipelineStackBetaStack2C79AD00A.template.json" + }, + "runOrder": 3, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Stack2.Deploy", + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Beta-Stack2", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "runOrder": 4, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + } + ] + }, + { + "name": "Wave1", + "actions": [ + { + "name": "Prod1.Stack1.Prepare", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod1-Stack1", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod1/PipelineStackProd1Stack14013D698.template.json" + }, + "runOrder": 1, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod2.Stack1.Prepare", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod2-Stack1", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod2/PipelineStackProd2Stack1FD464162.template.json" + }, + "runOrder": 1, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod1.Stack1.Deploy", + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod1-Stack1", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "runOrder": 2, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod2.Stack1.Deploy", + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod2-Stack1", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "runOrder": 2, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod1.Stack2.Prepare", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod1-Stack2", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod1/PipelineStackProd1Stack2F0681AFF.template.json" + }, + "runOrder": 3, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod2.Stack2.Prepare", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod2-Stack2", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod2/PipelineStackProd2Stack2176123EB.template.json" + }, + "runOrder": 3, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod1.Stack2.Deploy", + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod1-Stack2", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "runOrder": 4, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod2.Stack2.Deploy", + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod2-Stack2", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "runOrder": 4, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + } + ] + }, + { + "name": "Wave2", + "actions": [ + { + "name": "Prod3.Stack1.Prepare", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod3-Stack1", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod3/PipelineStackProd3Stack1795F3D43.template.json" + }, + "runOrder": 1, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod4.Stack1.Prepare", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod4-Stack1", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod4/PipelineStackProd4Stack118F74ADB.template.json" + }, + "runOrder": 1, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod5.Stack1.Prepare", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod5-Stack1", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod5/PipelineStackProd5Stack1E7E4E4C6.template.json" + }, + "runOrder": 1, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod6.Stack1.Prepare", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod6-Stack1", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod6/PipelineStackProd6Stack1E7C34314.template.json" + }, + "runOrder": 1, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod3.Stack1.Deploy", + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod3-Stack1", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "runOrder": 2, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod4.Stack1.Deploy", + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod4-Stack1", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "runOrder": 2, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod5.Stack1.Deploy", + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod5-Stack1", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "runOrder": 2, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod6.Stack1.Deploy", + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod6-Stack1", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "runOrder": 2, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod3.Stack2.Prepare", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod3-Stack2", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod3/PipelineStackProd3Stack2DFBBA0B2.template.json" + }, + "runOrder": 3, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod4.Stack2.Prepare", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod4-Stack2", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod4/PipelineStackProd4Stack2E2CB4ED3.template.json" + }, + "runOrder": 3, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod5.Stack2.Prepare", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod5-Stack2", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod5/PipelineStackProd5Stack2C39BEE5B.template.json" + }, + "runOrder": 3, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod6.Stack2.Prepare", + "inputArtifacts": [ + { + "name": "Synth_Output" + } + ], + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod6-Stack2", + "Capabilities": "CAPABILITY_NAMED_IAM,CAPABILITY_AUTO_EXPAND", + "RoleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-cfn-exec-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + }, + "ActionMode": "CHANGE_SET_REPLACE", + "ChangeSetName": "PipelineChange", + "TemplatePath": "Synth_Output::assembly-PipelineStack-Prod6/PipelineStackProd6Stack2BED1BBCE.template.json" + }, + "runOrder": 3, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod3.Stack2.Deploy", + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod3-Stack2", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "runOrder": 4, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod4.Stack2.Deploy", + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod4-Stack2", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "runOrder": 4, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod5.Stack2.Deploy", + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod5-Stack2", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "runOrder": 4, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + }, + { + "name": "Prod6.Stack2.Deploy", + "actionTypeId": { + "category": "Deploy", + "version": "1", + "owner": "AWS", + "provider": "CloudFormation" + }, + "configuration": { + "StackName": "Prod6-Stack2", + "ActionMode": "CHANGE_SET_EXECUTE", + "ChangeSetName": "PipelineChange" + }, + "runOrder": 4, + "roleArn": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/cdk-hnb659fds-deploy-role-", + { + "Ref": "AWS::AccountId" + }, + "-", + { + "Ref": "AWS::Region" + } + ] + ] + } + } + ] + } + ], + "artifactStore": { + "type": "S3", + "location": { + "Ref": "PipelineArtifactsBucketAEA9A052" + }, + "encryptionKey": { + "type": "KMS", + "id": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + } + } + }, + "restartExecutionOnUpdate": true + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-codepipeline.CfnPipeline", + "version": "0.0.0" + } + }, + "Source": { + "id": "Source", + "path": "PipelineStack/Pipeline/Pipeline/Source", + "children": { + "tkglaser_cdk-pipelines-demo": { + "id": "tkglaser_cdk-pipelines-demo", + "path": "PipelineStack/Pipeline/Pipeline/Source/tkglaser_cdk-pipelines-demo", + "children": { + "WebhookResource": { + "id": "WebhookResource", + "path": "PipelineStack/Pipeline/Pipeline/Source/tkglaser_cdk-pipelines-demo/WebhookResource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::CodePipeline::Webhook", + "aws:cdk:cloudformation:props": { + "authentication": "GITHUB_HMAC", + "authenticationConfiguration": { + "secretToken": "{{resolve:secretsmanager:github-token:SecretString:::}}" + }, + "filters": [ + { + "jsonPath": "$.ref", + "matchEquals": "refs/heads/{Branch}" + } + ], + "targetAction": "tkglaser_cdk-pipelines-demo", + "targetPipeline": { + "Ref": "Pipeline9850B417" + }, + "targetPipelineVersion": 1, + "registerWithThirdParty": true + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-codepipeline.CfnWebhook", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Build": { + "id": "Build", + "path": "PipelineStack/Pipeline/Pipeline/Build", + "children": { + "Synth": { + "id": "Synth", + "path": "PipelineStack/Pipeline/Pipeline/Build/Synth", + "children": { + "CdkBuildProject": { + "id": "CdkBuildProject", + "path": "PipelineStack/Pipeline/Pipeline/Build/Synth/CdkBuildProject", + "children": { + "Role": { + "id": "Role", + "path": "PipelineStack/Pipeline/Pipeline/Build/Synth/CdkBuildProject/Role", + "children": { + "ImportRole": { + "id": "ImportRole", + "path": "PipelineStack/Pipeline/Pipeline/Build/Synth/CdkBuildProject/Role/ImportRole", + "constructInfo": { + "fqn": "@aws-cdk/core.Resource", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/Pipeline/Build/Synth/CdkBuildProject/Role/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Role", + "aws:cdk:cloudformation:props": { + "assumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "codebuild.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.CfnRole", + "version": "0.0.0" + } + }, + "DefaultPolicy": { + "id": "DefaultPolicy", + "path": "PipelineStack/Pipeline/Pipeline/Build/Synth/CdkBuildProject/Role/DefaultPolicy", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/Pipeline/Build/Synth/CdkBuildProject/Role/DefaultPolicy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Policy", + "aws:cdk:cloudformation:props": { + "policyDocument": { + "Statement": [ + { + "Action": [ + "logs:CreateLogGroup", + "logs:CreateLogStream", + "logs:PutLogEvents" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/codebuild/", + { + "Ref": "PipelineBuildSynthCdkBuildProject6BEFA8E6" + }, + ":*" + ] + ] + }, + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/codebuild/", + { + "Ref": "PipelineBuildSynthCdkBuildProject6BEFA8E6" + } + ] + ] + } + ] + }, + { + "Action": [ + "codebuild:BatchPutCodeCoverages", + "codebuild:BatchPutTestCases", + "codebuild:CreateReport", + "codebuild:CreateReportGroup", + "codebuild:UpdateReport" + ], + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":codebuild:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":report-group/", + { + "Ref": "PipelineBuildSynthCdkBuildProject6BEFA8E6" + }, + "-*" + ] + ] + } + }, + { + "Action": [ + "s3:Abort*", + "s3:DeleteObject*", + "s3:GetBucket*", + "s3:GetObject*", + "s3:List*", + "s3:PutObject", + "s3:PutObjectLegalHold", + "s3:PutObjectRetention", + "s3:PutObjectTagging", + "s3:PutObjectVersionTagging" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "kms:Decrypt", + "kms:DescribeKey", + "kms:Encrypt", + "kms:GenerateDataKey*", + "kms:ReEncrypt*" + ], + "Effect": "Allow", + "Resource": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + } + } + ], + "Version": "2012-10-17" + }, + "policyName": "PipelineBuildSynthCdkBuildProjectRoleDefaultPolicyFB6C941C", + "roles": [ + { + "Ref": "PipelineBuildSynthCdkBuildProjectRole231EEA2A" + } + ] + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.CfnPolicy", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.Policy", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.Role", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/Pipeline/Build/Synth/CdkBuildProject/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::CodeBuild::Project", + "aws:cdk:cloudformation:props": { + "artifacts": { + "type": "CODEPIPELINE" + }, + "environment": { + "type": "LINUX_CONTAINER", + "image": "aws/codebuild/standard:5.0", + "imagePullCredentialsType": "CODEBUILD", + "privilegedMode": false, + "computeType": "BUILD_GENERAL1_SMALL" + }, + "serviceRole": { + "Fn::GetAtt": [ + "PipelineBuildSynthCdkBuildProjectRole231EEA2A", + "Arn" + ] + }, + "source": { + "type": "CODEPIPELINE", + "buildSpec": "{\n \"version\": \"0.2\",\n \"phases\": {\n \"build\": {\n \"commands\": [\n \"npm ci\",\n \"npm run build\",\n \"npx cdk synth\"\n ]\n }\n },\n \"artifacts\": {\n \"base-directory\": \"cdk.out\",\n \"files\": \"**/*\"\n }\n}" + }, + "cache": { + "type": "NO_CACHE" + }, + "description": "Pipeline step PipelineStack/Pipeline/Build/Synth", + "encryptionKey": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-codebuild.CfnProject", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-codebuild.PipelineProject", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "UpdatePipeline": { + "id": "UpdatePipeline", + "path": "PipelineStack/Pipeline/Pipeline/UpdatePipeline", + "children": { + "SelfMutate": { + "id": "SelfMutate", + "path": "PipelineStack/Pipeline/Pipeline/UpdatePipeline/SelfMutate", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Beta": { + "id": "Beta", + "path": "PipelineStack/Pipeline/Pipeline/Beta", + "children": { + "Stack1.Prepare": { + "id": "Stack1.Prepare", + "path": "PipelineStack/Pipeline/Pipeline/Beta/Stack1.Prepare", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Stack1.Deploy": { + "id": "Stack1.Deploy", + "path": "PipelineStack/Pipeline/Pipeline/Beta/Stack1.Deploy", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Stack2.Prepare": { + "id": "Stack2.Prepare", + "path": "PipelineStack/Pipeline/Pipeline/Beta/Stack2.Prepare", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Stack2.Deploy": { + "id": "Stack2.Deploy", + "path": "PipelineStack/Pipeline/Pipeline/Beta/Stack2.Deploy", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "MutableRolearn:${AWS::Partition}:iam::${AWS::AccountId}:role--cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}": { + "id": "MutableRolearn:${AWS::Partition}:iam::${AWS::AccountId}:role--cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "path": "PipelineStack/Pipeline/Pipeline/MutableRolearn:${AWS::Partition}:iam::${AWS::AccountId}:role--cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "constructInfo": { + "fqn": "@aws-cdk/core.Resource", + "version": "0.0.0" + } + }, + "arn:${AWS::Partition}:iam::${AWS::AccountId}:role--cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}": { + "id": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role--cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "path": "PipelineStack/Pipeline/Pipeline/arn:${AWS::Partition}:iam::${AWS::AccountId}:role--cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "children": { + "8389e75f-0810-4838-bf64-d6f85a95cf83": { + "id": "8389e75f-0810-4838-bf64-d6f85a95cf83", + "path": "PipelineStack/Pipeline/Pipeline/arn:${AWS::Partition}:iam::${AWS::AccountId}:role--cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}/8389e75f-0810-4838-bf64-d6f85a95cf83", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Resource", + "version": "0.0.0" + } + }, + "MutableRolearn:${AWS::Partition}:iam::${AWS::AccountId}:role--cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}": { + "id": "MutableRolearn:${AWS::Partition}:iam::${AWS::AccountId}:role--cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "path": "PipelineStack/Pipeline/Pipeline/MutableRolearn:${AWS::Partition}:iam::${AWS::AccountId}:role--cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "constructInfo": { + "fqn": "@aws-cdk/core.Resource", + "version": "0.0.0" + } + }, + "arn:${AWS::Partition}:iam::${AWS::AccountId}:role--cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}": { + "id": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role--cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "path": "PipelineStack/Pipeline/Pipeline/arn:${AWS::Partition}:iam::${AWS::AccountId}:role--cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "constructInfo": { + "fqn": "@aws-cdk/core.Resource", + "version": "0.0.0" + } + }, + "Wave1": { + "id": "Wave1", + "path": "PipelineStack/Pipeline/Pipeline/Wave1", + "children": { + "Prod1.Stack1.Prepare": { + "id": "Prod1.Stack1.Prepare", + "path": "PipelineStack/Pipeline/Pipeline/Wave1/Prod1.Stack1.Prepare", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod2.Stack1.Prepare": { + "id": "Prod2.Stack1.Prepare", + "path": "PipelineStack/Pipeline/Pipeline/Wave1/Prod2.Stack1.Prepare", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod1.Stack1.Deploy": { + "id": "Prod1.Stack1.Deploy", + "path": "PipelineStack/Pipeline/Pipeline/Wave1/Prod1.Stack1.Deploy", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod2.Stack1.Deploy": { + "id": "Prod2.Stack1.Deploy", + "path": "PipelineStack/Pipeline/Pipeline/Wave1/Prod2.Stack1.Deploy", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod1.Stack2.Prepare": { + "id": "Prod1.Stack2.Prepare", + "path": "PipelineStack/Pipeline/Pipeline/Wave1/Prod1.Stack2.Prepare", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod2.Stack2.Prepare": { + "id": "Prod2.Stack2.Prepare", + "path": "PipelineStack/Pipeline/Pipeline/Wave1/Prod2.Stack2.Prepare", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod1.Stack2.Deploy": { + "id": "Prod1.Stack2.Deploy", + "path": "PipelineStack/Pipeline/Pipeline/Wave1/Prod1.Stack2.Deploy", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod2.Stack2.Deploy": { + "id": "Prod2.Stack2.Deploy", + "path": "PipelineStack/Pipeline/Pipeline/Wave1/Prod2.Stack2.Deploy", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Wave2": { + "id": "Wave2", + "path": "PipelineStack/Pipeline/Pipeline/Wave2", + "children": { + "Prod3.Stack1.Prepare": { + "id": "Prod3.Stack1.Prepare", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod3.Stack1.Prepare", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod4.Stack1.Prepare": { + "id": "Prod4.Stack1.Prepare", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod4.Stack1.Prepare", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod5.Stack1.Prepare": { + "id": "Prod5.Stack1.Prepare", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod5.Stack1.Prepare", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod6.Stack1.Prepare": { + "id": "Prod6.Stack1.Prepare", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod6.Stack1.Prepare", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod3.Stack1.Deploy": { + "id": "Prod3.Stack1.Deploy", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod3.Stack1.Deploy", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod4.Stack1.Deploy": { + "id": "Prod4.Stack1.Deploy", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod4.Stack1.Deploy", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod5.Stack1.Deploy": { + "id": "Prod5.Stack1.Deploy", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod5.Stack1.Deploy", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod6.Stack1.Deploy": { + "id": "Prod6.Stack1.Deploy", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod6.Stack1.Deploy", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod3.Stack2.Prepare": { + "id": "Prod3.Stack2.Prepare", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod3.Stack2.Prepare", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod4.Stack2.Prepare": { + "id": "Prod4.Stack2.Prepare", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod4.Stack2.Prepare", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod5.Stack2.Prepare": { + "id": "Prod5.Stack2.Prepare", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod5.Stack2.Prepare", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod6.Stack2.Prepare": { + "id": "Prod6.Stack2.Prepare", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod6.Stack2.Prepare", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod3.Stack2.Deploy": { + "id": "Prod3.Stack2.Deploy", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod3.Stack2.Deploy", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod4.Stack2.Deploy": { + "id": "Prod4.Stack2.Deploy", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod4.Stack2.Deploy", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod5.Stack2.Deploy": { + "id": "Prod5.Stack2.Deploy", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod5.Stack2.Deploy", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "Prod6.Stack2.Deploy": { + "id": "Prod6.Stack2.Deploy", + "path": "PipelineStack/Pipeline/Pipeline/Wave2/Prod6.Stack2.Deploy", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-codepipeline.Pipeline", + "version": "0.0.0" + } + }, + "CodeBuildActionRole": { + "id": "CodeBuildActionRole", + "path": "PipelineStack/Pipeline/CodeBuildActionRole", + "children": { + "ImportCodeBuildActionRole": { + "id": "ImportCodeBuildActionRole", + "path": "PipelineStack/Pipeline/CodeBuildActionRole/ImportCodeBuildActionRole", + "constructInfo": { + "fqn": "@aws-cdk/core.Resource", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/CodeBuildActionRole/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Role", + "aws:cdk:cloudformation:props": { + "assumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Condition": { + "Bool": { + "aws:ViaAWSService": "codepipeline.amazonaws.com" + } + }, + "Effect": "Allow", + "Principal": { + "AWS": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":iam::", + { + "Ref": "AWS::AccountId" + }, + ":root" + ] + ] + } + } + } + ], + "Version": "2012-10-17" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.CfnRole", + "version": "0.0.0" + } + }, + "DefaultPolicy": { + "id": "DefaultPolicy", + "path": "PipelineStack/Pipeline/CodeBuildActionRole/DefaultPolicy", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/CodeBuildActionRole/DefaultPolicy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Policy", + "aws:cdk:cloudformation:props": { + "policyDocument": { + "Statement": [ + { + "Action": [ + "codebuild:BatchGetBuilds", + "codebuild:StartBuild", + "codebuild:StopBuild" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::GetAtt": [ + "PipelineBuildSynthCdkBuildProject6BEFA8E6", + "Arn" + ] + }, + { + "Fn::GetAtt": [ + "PipelineUpdatePipelineSelfMutationDAA41400", + "Arn" + ] + } + ] + } + ], + "Version": "2012-10-17" + }, + "policyName": "PipelineCodeBuildActionRoleDefaultPolicy1D62A6FE", + "roles": [ + { + "Ref": "PipelineCodeBuildActionRole226DB0CB" + } + ] + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.CfnPolicy", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.Policy", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.Role", + "version": "0.0.0" + } + }, + "UpdatePipeline": { + "id": "UpdatePipeline", + "path": "PipelineStack/Pipeline/UpdatePipeline", + "children": { + "SelfMutation": { + "id": "SelfMutation", + "path": "PipelineStack/Pipeline/UpdatePipeline/SelfMutation", + "children": { + "Role": { + "id": "Role", + "path": "PipelineStack/Pipeline/UpdatePipeline/SelfMutation/Role", + "children": { + "ImportRole": { + "id": "ImportRole", + "path": "PipelineStack/Pipeline/UpdatePipeline/SelfMutation/Role/ImportRole", + "constructInfo": { + "fqn": "@aws-cdk/core.Resource", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/UpdatePipeline/SelfMutation/Role/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Role", + "aws:cdk:cloudformation:props": { + "assumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "codebuild.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.CfnRole", + "version": "0.0.0" + } + }, + "DefaultPolicy": { + "id": "DefaultPolicy", + "path": "PipelineStack/Pipeline/UpdatePipeline/SelfMutation/Role/DefaultPolicy", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/UpdatePipeline/SelfMutation/Role/DefaultPolicy/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::IAM::Policy", + "aws:cdk:cloudformation:props": { + "policyDocument": { + "Statement": [ + { + "Action": [ + "logs:CreateLogGroup", + "logs:CreateLogStream", + "logs:PutLogEvents" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/codebuild/", + { + "Ref": "PipelineUpdatePipelineSelfMutationDAA41400" + }, + ":*" + ] + ] + }, + { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":logs:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":log-group:/aws/codebuild/", + { + "Ref": "PipelineUpdatePipelineSelfMutationDAA41400" + } + ] + ] + } + ] + }, + { + "Action": [ + "codebuild:BatchPutCodeCoverages", + "codebuild:BatchPutTestCases", + "codebuild:CreateReport", + "codebuild:CreateReportGroup", + "codebuild:UpdateReport" + ], + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:", + { + "Ref": "AWS::Partition" + }, + ":codebuild:", + { + "Ref": "AWS::Region" + }, + ":", + { + "Ref": "AWS::AccountId" + }, + ":report-group/", + { + "Ref": "PipelineUpdatePipelineSelfMutationDAA41400" + }, + "-*" + ] + ] + } + }, + { + "Action": "sts:AssumeRole", + "Condition": { + "ForAnyValue:StringEquals": { + "iam:ResourceTag/aws-cdk:bootstrap-role": [ + "image-publishing", + "file-publishing", + "deploy" + ] + } + }, + "Effect": "Allow", + "Resource": { + "Fn::Join": [ + "", + [ + "arn:*:iam::", + { + "Ref": "AWS::AccountId" + }, + ":role/*" + ] + ] + } + }, + { + "Action": [ + "cloudformation:DescribeStacks", + "s3:ListBucket" + ], + "Effect": "Allow", + "Resource": "*" + }, + { + "Action": [ + "s3:GetBucket*", + "s3:GetObject*", + "s3:List*" + ], + "Effect": "Allow", + "Resource": [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + { + "Fn::Join": [ + "", + [ + { + "Fn::GetAtt": [ + "PipelineArtifactsBucketAEA9A052", + "Arn" + ] + }, + "/*" + ] + ] + } + ] + }, + { + "Action": [ + "kms:Decrypt", + "kms:DescribeKey", + "kms:Encrypt", + "kms:GenerateDataKey*", + "kms:ReEncrypt*" + ], + "Effect": "Allow", + "Resource": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + } + } + ], + "Version": "2012-10-17" + }, + "policyName": "PipelineUpdatePipelineSelfMutationRoleDefaultPolicyA225DA4E", + "roles": [ + { + "Ref": "PipelineUpdatePipelineSelfMutationRole57E559E8" + } + ] + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.CfnPolicy", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.Policy", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-iam.Role", + "version": "0.0.0" + } + }, + "Resource": { + "id": "Resource", + "path": "PipelineStack/Pipeline/UpdatePipeline/SelfMutation/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::CodeBuild::Project", + "aws:cdk:cloudformation:props": { + "artifacts": { + "type": "CODEPIPELINE" + }, + "environment": { + "type": "LINUX_CONTAINER", + "image": "aws/codebuild/standard:5.0", + "imagePullCredentialsType": "CODEBUILD", + "privilegedMode": false, + "computeType": "BUILD_GENERAL1_SMALL" + }, + "serviceRole": { + "Fn::GetAtt": [ + "PipelineUpdatePipelineSelfMutationRole57E559E8", + "Arn" + ] + }, + "source": { + "type": "CODEPIPELINE", + "buildSpec": "{\n \"version\": \"0.2\",\n \"phases\": {\n \"install\": {\n \"commands\": [\n \"npm install -g aws-cdk@1\"\n ]\n },\n \"build\": {\n \"commands\": [\n \"cdk -a . deploy PipelineStack --require-approval=never --verbose\"\n ]\n }\n }\n}" + }, + "cache": { + "type": "NO_CACHE" + }, + "description": "Pipeline step PipelineStack/Pipeline/UpdatePipeline/SelfMutate", + "encryptionKey": { + "Fn::GetAtt": [ + "PipelineArtifactsBucketEncryptionKeyF5BF0670", + "Arn" + ] + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-codebuild.CfnProject", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-codebuild.PipelineProject", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/pipelines.CodePipeline", + "version": "0.0.0" + } + }, + "Beta": { + "id": "Beta", + "path": "PipelineStack/Beta", + "children": { + "Stack1": { + "id": "Stack1", + "path": "PipelineStack/Beta/Stack1", + "children": { + "Queue": { + "id": "Queue", + "path": "PipelineStack/Beta/Stack1/Queue", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Beta/Stack1/Queue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": {} + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.CfnQueue", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.Queue", + "version": "0.0.0" + } + }, + "Exports": { + "id": "Exports", + "path": "PipelineStack/Beta/Stack1/Exports", + "children": { + "Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}": { + "id": "Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}", + "path": "PipelineStack/Beta/Stack1/Exports/Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnOutput", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/Beta/Stack1/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/Beta/Stack1/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + }, + "Stack2": { + "id": "Stack2", + "path": "PipelineStack/Beta/Stack2", + "children": { + "OtherQueue": { + "id": "OtherQueue", + "path": "PipelineStack/Beta/Stack2/OtherQueue", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Beta/Stack2/OtherQueue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": { + "redrivePolicy": { + "deadLetterTargetArn": { + "Fn::ImportValue": "Beta-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + }, + "maxReceiveCount": 5 + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.CfnQueue", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.Queue", + "version": "0.0.0" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/Beta/Stack2/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/Beta/Stack2/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stage", + "version": "0.0.0" + } + }, + "Prod1": { + "id": "Prod1", + "path": "PipelineStack/Prod1", + "children": { + "Stack1": { + "id": "Stack1", + "path": "PipelineStack/Prod1/Stack1", + "children": { + "Queue": { + "id": "Queue", + "path": "PipelineStack/Prod1/Stack1/Queue", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Prod1/Stack1/Queue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": {} + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.CfnQueue", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.Queue", + "version": "0.0.0" + } + }, + "Exports": { + "id": "Exports", + "path": "PipelineStack/Prod1/Stack1/Exports", + "children": { + "Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}": { + "id": "Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}", + "path": "PipelineStack/Prod1/Stack1/Exports/Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnOutput", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/Prod1/Stack1/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/Prod1/Stack1/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + }, + "Stack2": { + "id": "Stack2", + "path": "PipelineStack/Prod1/Stack2", + "children": { + "OtherQueue": { + "id": "OtherQueue", + "path": "PipelineStack/Prod1/Stack2/OtherQueue", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Prod1/Stack2/OtherQueue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": { + "redrivePolicy": { + "deadLetterTargetArn": { + "Fn::ImportValue": "Prod1-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + }, + "maxReceiveCount": 5 + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.CfnQueue", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.Queue", + "version": "0.0.0" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/Prod1/Stack2/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/Prod1/Stack2/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stage", + "version": "0.0.0" + } + }, + "Prod2": { + "id": "Prod2", + "path": "PipelineStack/Prod2", + "children": { + "Stack1": { + "id": "Stack1", + "path": "PipelineStack/Prod2/Stack1", + "children": { + "Queue": { + "id": "Queue", + "path": "PipelineStack/Prod2/Stack1/Queue", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Prod2/Stack1/Queue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": {} + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.CfnQueue", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.Queue", + "version": "0.0.0" + } + }, + "Exports": { + "id": "Exports", + "path": "PipelineStack/Prod2/Stack1/Exports", + "children": { + "Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}": { + "id": "Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}", + "path": "PipelineStack/Prod2/Stack1/Exports/Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnOutput", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/Prod2/Stack1/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/Prod2/Stack1/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + }, + "Stack2": { + "id": "Stack2", + "path": "PipelineStack/Prod2/Stack2", + "children": { + "OtherQueue": { + "id": "OtherQueue", + "path": "PipelineStack/Prod2/Stack2/OtherQueue", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Prod2/Stack2/OtherQueue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": { + "redrivePolicy": { + "deadLetterTargetArn": { + "Fn::ImportValue": "Prod2-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + }, + "maxReceiveCount": 5 + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.CfnQueue", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.Queue", + "version": "0.0.0" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/Prod2/Stack2/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/Prod2/Stack2/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stage", + "version": "0.0.0" + } + }, + "Prod3": { + "id": "Prod3", + "path": "PipelineStack/Prod3", + "children": { + "Stack1": { + "id": "Stack1", + "path": "PipelineStack/Prod3/Stack1", + "children": { + "Queue": { + "id": "Queue", + "path": "PipelineStack/Prod3/Stack1/Queue", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Prod3/Stack1/Queue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": {} + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.CfnQueue", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.Queue", + "version": "0.0.0" + } + }, + "Exports": { + "id": "Exports", + "path": "PipelineStack/Prod3/Stack1/Exports", + "children": { + "Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}": { + "id": "Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}", + "path": "PipelineStack/Prod3/Stack1/Exports/Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnOutput", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/Prod3/Stack1/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/Prod3/Stack1/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + }, + "Stack2": { + "id": "Stack2", + "path": "PipelineStack/Prod3/Stack2", + "children": { + "OtherQueue": { + "id": "OtherQueue", + "path": "PipelineStack/Prod3/Stack2/OtherQueue", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Prod3/Stack2/OtherQueue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": { + "redrivePolicy": { + "deadLetterTargetArn": { + "Fn::ImportValue": "Prod3-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + }, + "maxReceiveCount": 5 + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.CfnQueue", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.Queue", + "version": "0.0.0" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/Prod3/Stack2/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/Prod3/Stack2/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stage", + "version": "0.0.0" + } + }, + "Prod4": { + "id": "Prod4", + "path": "PipelineStack/Prod4", + "children": { + "Stack1": { + "id": "Stack1", + "path": "PipelineStack/Prod4/Stack1", + "children": { + "Queue": { + "id": "Queue", + "path": "PipelineStack/Prod4/Stack1/Queue", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Prod4/Stack1/Queue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": {} + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.CfnQueue", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.Queue", + "version": "0.0.0" + } + }, + "Exports": { + "id": "Exports", + "path": "PipelineStack/Prod4/Stack1/Exports", + "children": { + "Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}": { + "id": "Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}", + "path": "PipelineStack/Prod4/Stack1/Exports/Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnOutput", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/Prod4/Stack1/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/Prod4/Stack1/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + }, + "Stack2": { + "id": "Stack2", + "path": "PipelineStack/Prod4/Stack2", + "children": { + "OtherQueue": { + "id": "OtherQueue", + "path": "PipelineStack/Prod4/Stack2/OtherQueue", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Prod4/Stack2/OtherQueue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": { + "redrivePolicy": { + "deadLetterTargetArn": { + "Fn::ImportValue": "Prod4-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + }, + "maxReceiveCount": 5 + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.CfnQueue", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.Queue", + "version": "0.0.0" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/Prod4/Stack2/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/Prod4/Stack2/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stage", + "version": "0.0.0" + } + }, + "Prod5": { + "id": "Prod5", + "path": "PipelineStack/Prod5", + "children": { + "Stack1": { + "id": "Stack1", + "path": "PipelineStack/Prod5/Stack1", + "children": { + "Queue": { + "id": "Queue", + "path": "PipelineStack/Prod5/Stack1/Queue", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Prod5/Stack1/Queue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": {} + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.CfnQueue", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.Queue", + "version": "0.0.0" + } + }, + "Exports": { + "id": "Exports", + "path": "PipelineStack/Prod5/Stack1/Exports", + "children": { + "Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}": { + "id": "Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}", + "path": "PipelineStack/Prod5/Stack1/Exports/Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnOutput", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/Prod5/Stack1/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/Prod5/Stack1/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + }, + "Stack2": { + "id": "Stack2", + "path": "PipelineStack/Prod5/Stack2", + "children": { + "OtherQueue": { + "id": "OtherQueue", + "path": "PipelineStack/Prod5/Stack2/OtherQueue", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Prod5/Stack2/OtherQueue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": { + "redrivePolicy": { + "deadLetterTargetArn": { + "Fn::ImportValue": "Prod5-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + }, + "maxReceiveCount": 5 + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.CfnQueue", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.Queue", + "version": "0.0.0" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/Prod5/Stack2/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/Prod5/Stack2/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stage", + "version": "0.0.0" + } + }, + "Prod6": { + "id": "Prod6", + "path": "PipelineStack/Prod6", + "children": { + "Stack1": { + "id": "Stack1", + "path": "PipelineStack/Prod6/Stack1", + "children": { + "Queue": { + "id": "Queue", + "path": "PipelineStack/Prod6/Stack1/Queue", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Prod6/Stack1/Queue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": {} + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.CfnQueue", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.Queue", + "version": "0.0.0" + } + }, + "Exports": { + "id": "Exports", + "path": "PipelineStack/Prod6/Stack1/Exports", + "children": { + "Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}": { + "id": "Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}", + "path": "PipelineStack/Prod6/Stack1/Exports/Output{\"Fn::GetAtt\":[\"Queue4A7E3555\",\"Arn\"]}", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnOutput", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/Prod6/Stack1/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/Prod6/Stack1/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + }, + "Stack2": { + "id": "Stack2", + "path": "PipelineStack/Prod6/Stack2", + "children": { + "OtherQueue": { + "id": "OtherQueue", + "path": "PipelineStack/Prod6/Stack2/OtherQueue", + "children": { + "Resource": { + "id": "Resource", + "path": "PipelineStack/Prod6/Stack2/OtherQueue/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::SQS::Queue", + "aws:cdk:cloudformation:props": { + "redrivePolicy": { + "deadLetterTargetArn": { + "Fn::ImportValue": "Prod6-Stack1:ExportsOutputFnGetAttQueue4A7E3555Arn15A7202E" + }, + "maxReceiveCount": 5 + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.CfnQueue", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/aws-sqs.Queue", + "version": "0.0.0" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/Prod6/Stack2/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/Prod6/Stack2/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stage", + "version": "0.0.0" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "PipelineStack/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "PipelineStack/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + }, + "LambdaTest": { + "id": "LambdaTest", + "path": "LambdaTest", + "children": { + "DefaultTest": { + "id": "DefaultTest", + "path": "LambdaTest/DefaultTest", + "children": { + "Default": { + "id": "Default", + "path": "LambdaTest/DefaultTest/Default", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + }, + "DeployAssert": { + "id": "DeployAssert", + "path": "LambdaTest/DefaultTest/DeployAssert", + "children": { + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "LambdaTest/DefaultTest/DeployAssert/BootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnParameter", + "version": "0.0.0" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "LambdaTest/DefaultTest/DeployAssert/CheckBootstrapVersion", + "constructInfo": { + "fqn": "@aws-cdk/core.CfnRule", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.Stack", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/integ-tests.IntegTestCase", + "version": "0.0.0" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/integ-tests.IntegTest", + "version": "0.0.0" + } + }, + "Tree": { + "id": "Tree", + "path": "Tree", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.1.189" + } + } + }, + "constructInfo": { + "fqn": "@aws-cdk/core.App", + "version": "0.0.0" + } + } +} \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.ts b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.ts new file mode 100644 index 0000000000000..de79adf2b5081 --- /dev/null +++ b/packages/@aws-cdk/pipelines/test/integ.newpipeline-with-cross-account-keys.ts @@ -0,0 +1,64 @@ +import * as sqs from '@aws-cdk/aws-sqs'; +import { App, Stack, StackProps, Stage, StageProps } from '@aws-cdk/core'; +import * as integ from '@aws-cdk/integ-tests'; +import { Construct } from 'constructs'; + +import * as pipelines from '../lib'; + +class PipelineStack extends Stack { + constructor(scope: Construct, id: string, props?: StackProps) { + super(scope, id, props); + + const pipeline = new pipelines.CodePipeline(this, 'Pipeline', { + crossAccountKeys: true, + enableKeyRotation: true, + synth: new pipelines.ShellStep('Synth', { + input: pipelines.CodePipelineSource.gitHub('tkglaser/cdk-pipelines-demo', 'main'), + commands: [ + 'npm ci', + 'npm run build', + 'npx cdk synth', + ], + }), + }); + + pipeline.addStage(new AppStage(this, 'Beta')); + + const group = pipeline.addWave('Wave1'); + group.addStage(new AppStage(this, 'Prod1')); + group.addStage(new AppStage(this, 'Prod2')); + + const group2 = pipeline.addWave('Wave2'); + group2.addStage(new AppStage(this, 'Prod3')); + group2.addStage(new AppStage(this, 'Prod4')); + group2.addStage(new AppStage(this, 'Prod5')); + group2.addStage(new AppStage(this, 'Prod6')); + } +} + +class AppStage extends Stage { + constructor(scope: Construct, id: string, props?: StageProps) { + super(scope, id, props); + + const stack1 = new Stack(this, 'Stack1'); + const queue1 = new sqs.Queue(stack1, 'Queue'); + + const stack2 = new Stack(this, 'Stack2'); + new sqs.Queue(stack2, 'OtherQueue', { + deadLetterQueue: { + queue: queue1, + maxReceiveCount: 5, + }, + }); + } +} + +const app = new App(); + +const stack = new PipelineStack(app, 'PipelineStack'); + +new integ.IntegTest(app, 'LambdaTest', { + testCases: [stack], +}); + +app.synth(); \ No newline at end of file diff --git a/packages/@aws-cdk/pipelines/test/testhelpers/test-app.ts b/packages/@aws-cdk/pipelines/test/testhelpers/test-app.ts index fca2cd26f04d4..da35f1b979f4e 100644 --- a/packages/@aws-cdk/pipelines/test/testhelpers/test-app.ts +++ b/packages/@aws-cdk/pipelines/test/testhelpers/test-app.ts @@ -75,14 +75,28 @@ export class AppWithOutput extends Stage { } } +export interface TwoStackAppProps extends StageProps { + /** + * Create a dependency between the two stacks + * + * @default true + */ + readonly withDependency?: boolean; +} + export class TwoStackApp extends Stage { - constructor(scope: Construct, id: string, props?: StageProps) { + public readonly stack1: Stack; + public readonly stack2: Stack; + + constructor(scope: Construct, id: string, props?: TwoStackAppProps) { super(scope, id, props); - const stack2 = new BucketStack(this, 'Stack2'); - const stack1 = new BucketStack(this, 'Stack1'); + this.stack2 = new BucketStack(this, 'Stack2'); + this.stack1 = new BucketStack(this, 'Stack1'); - stack2.addDependency(stack1); + if (props?.withDependency ?? true) { + this.stack2.addDependency(this.stack1); + } } } diff --git a/packages/@aws-cdk/region-info/build-tools/fact-tables.ts b/packages/@aws-cdk/region-info/build-tools/fact-tables.ts index 1eb700f733e1e..daac2ea673dd8 100644 --- a/packages/@aws-cdk/region-info/build-tools/fact-tables.ts +++ b/packages/@aws-cdk/region-info/build-tools/fact-tables.ts @@ -507,6 +507,44 @@ export const FIREHOSE_CIDR_BLOCKS: { [region: string]: string } = { }; const ADOT_LAMBDA_LAYER_JAVA_SDK_ARNS: { [version: string]: { [arch: string]: { [region: string]: string } } } = { + '1.21.0': { + x86_64: { + 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'ap-northeast-2': 'arn:aws:lambda:ap-northeast-2:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'ap-south-1': 'arn:aws:lambda:ap-south-1:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'ap-southeast-1': 'arn:aws:lambda:ap-southeast-1:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'ap-southeast-2': 'arn:aws:lambda:ap-southeast-2:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'ca-central-1': 'arn:aws:lambda:ca-central-1:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'eu-central-1': 'arn:aws:lambda:eu-central-1:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'eu-north-1': 'arn:aws:lambda:eu-north-1:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'eu-west-1': 'arn:aws:lambda:eu-west-1:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'eu-west-2': 'arn:aws:lambda:eu-west-2:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'eu-west-3': 'arn:aws:lambda:eu-west-3:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'sa-east-1': 'arn:aws:lambda:sa-east-1:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'us-east-1': 'arn:aws:lambda:us-east-1:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'us-east-2': 'arn:aws:lambda:us-east-2:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'us-west-1': 'arn:aws:lambda:us-west-1:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + 'us-west-2': 'arn:aws:lambda:us-west-2:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-21-0:1', + }, + arm64: { + 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'ap-northeast-2': 'arn:aws:lambda:ap-northeast-2:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'ap-south-1': 'arn:aws:lambda:ap-south-1:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'ap-southeast-1': 'arn:aws:lambda:ap-southeast-1:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'ap-southeast-2': 'arn:aws:lambda:ap-southeast-2:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'ca-central-1': 'arn:aws:lambda:ca-central-1:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'eu-central-1': 'arn:aws:lambda:eu-central-1:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'eu-north-1': 'arn:aws:lambda:eu-north-1:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'eu-west-1': 'arn:aws:lambda:eu-west-1:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'eu-west-2': 'arn:aws:lambda:eu-west-2:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'eu-west-3': 'arn:aws:lambda:eu-west-3:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'sa-east-1': 'arn:aws:lambda:sa-east-1:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'us-east-1': 'arn:aws:lambda:us-east-1:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'us-east-2': 'arn:aws:lambda:us-east-2:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'us-west-1': 'arn:aws:lambda:us-west-1:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + 'us-west-2': 'arn:aws:lambda:us-west-2:901920570463:layer:aws-otel-java-wrapper-arm64-ver-1-21-0:1', + }, + }, '1.19.0': { x86_64: { 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-java-wrapper-amd64-ver-1-19-0:1', @@ -550,6 +588,44 @@ const ADOT_LAMBDA_LAYER_JAVA_SDK_ARNS: { [version: string]: { [arch: string]: { const ADOT_LAMBDA_LAYER_JAVA_AUTO_INSTRUMENTATION_ARNS: { [version: string]: { [arch: string]: { [region: string]: string } }; } = { + '1.21.0': { + x86_64: { + 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'ap-northeast-2': 'arn:aws:lambda:ap-northeast-2:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'ap-south-1': 'arn:aws:lambda:ap-south-1:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'ap-southeast-1': 'arn:aws:lambda:ap-southeast-1:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'ap-southeast-2': 'arn:aws:lambda:ap-southeast-2:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'ca-central-1': 'arn:aws:lambda:ca-central-1:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'eu-central-1': 'arn:aws:lambda:eu-central-1:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'eu-north-1': 'arn:aws:lambda:eu-north-1:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'eu-west-1': 'arn:aws:lambda:eu-west-1:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'eu-west-2': 'arn:aws:lambda:eu-west-2:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'eu-west-3': 'arn:aws:lambda:eu-west-3:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'sa-east-1': 'arn:aws:lambda:sa-east-1:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'us-east-1': 'arn:aws:lambda:us-east-1:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'us-east-2': 'arn:aws:lambda:us-east-2:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'us-west-1': 'arn:aws:lambda:us-west-1:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + 'us-west-2': 'arn:aws:lambda:us-west-2:901920570463:layer:aws-otel-java-agent-amd64-ver-1-21-0:1', + }, + arm64: { + 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'ap-northeast-2': 'arn:aws:lambda:ap-northeast-2:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'ap-south-1': 'arn:aws:lambda:ap-south-1:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'ap-southeast-1': 'arn:aws:lambda:ap-southeast-1:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'ap-southeast-2': 'arn:aws:lambda:ap-southeast-2:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'ca-central-1': 'arn:aws:lambda:ca-central-1:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'eu-central-1': 'arn:aws:lambda:eu-central-1:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'eu-north-1': 'arn:aws:lambda:eu-north-1:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'eu-west-1': 'arn:aws:lambda:eu-west-1:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'eu-west-2': 'arn:aws:lambda:eu-west-2:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'eu-west-3': 'arn:aws:lambda:eu-west-3:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'sa-east-1': 'arn:aws:lambda:sa-east-1:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'us-east-1': 'arn:aws:lambda:us-east-1:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'us-east-2': 'arn:aws:lambda:us-east-2:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'us-west-1': 'arn:aws:lambda:us-west-1:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + 'us-west-2': 'arn:aws:lambda:us-west-2:901920570463:layer:aws-otel-java-agent-arm64-ver-1-21-0:1', + }, + }, '1.19.2': { x86_64: { 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-java-agent-amd64-ver-1-19-2:1', @@ -591,6 +667,44 @@ const ADOT_LAMBDA_LAYER_JAVA_AUTO_INSTRUMENTATION_ARNS: { }; const ADOT_LAMBDA_LAYER_JAVASCRIPT_SDK_ARNS: { [version: string]: { [arch: string]: { [region: string]: string } } } = { + '1.8.0': { + x86_64: { + 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'ap-northeast-2': 'arn:aws:lambda:ap-northeast-2:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'ap-south-1': 'arn:aws:lambda:ap-south-1:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'ap-southeast-1': 'arn:aws:lambda:ap-southeast-1:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'ap-southeast-2': 'arn:aws:lambda:ap-southeast-2:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'ca-central-1': 'arn:aws:lambda:ca-central-1:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'eu-central-1': 'arn:aws:lambda:eu-central-1:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'eu-north-1': 'arn:aws:lambda:eu-north-1:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'eu-west-1': 'arn:aws:lambda:eu-west-1:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'eu-west-2': 'arn:aws:lambda:eu-west-2:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'eu-west-3': 'arn:aws:lambda:eu-west-3:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'sa-east-1': 'arn:aws:lambda:sa-east-1:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'us-east-1': 'arn:aws:lambda:us-east-1:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'us-east-2': 'arn:aws:lambda:us-east-2:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'us-west-1': 'arn:aws:lambda:us-west-1:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + 'us-west-2': 'arn:aws:lambda:us-west-2:901920570463:layer:aws-otel-nodejs-amd64-ver-1-8-0:2', + }, + arm64: { + 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'ap-northeast-2': 'arn:aws:lambda:ap-northeast-2:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'ap-south-1': 'arn:aws:lambda:ap-south-1:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'ap-southeast-1': 'arn:aws:lambda:ap-southeast-1:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'ap-southeast-2': 'arn:aws:lambda:ap-southeast-2:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'ca-central-1': 'arn:aws:lambda:ca-central-1:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'eu-central-1': 'arn:aws:lambda:eu-central-1:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'eu-north-1': 'arn:aws:lambda:eu-north-1:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'eu-west-1': 'arn:aws:lambda:eu-west-1:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'eu-west-2': 'arn:aws:lambda:eu-west-2:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'eu-west-3': 'arn:aws:lambda:eu-west-3:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'sa-east-1': 'arn:aws:lambda:sa-east-1:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'us-east-1': 'arn:aws:lambda:us-east-1:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'us-east-2': 'arn:aws:lambda:us-east-2:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'us-west-1': 'arn:aws:lambda:us-west-1:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + 'us-west-2': 'arn:aws:lambda:us-west-2:901920570463:layer:aws-otel-nodejs-arm64-ver-1-8-0:2', + }, + }, '1.7.0': { x86_64: { 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-nodejs-amd64-ver-1-7-0:2', @@ -632,6 +746,44 @@ const ADOT_LAMBDA_LAYER_JAVASCRIPT_SDK_ARNS: { [version: string]: { [arch: strin }; const ADOT_LAMBDA_LAYER_PYTHON_SDK_ARNS: { [version: string]: { [arch: string]: { [region: string]: string } } } = { + '1.15.0': { + x86_64: { + 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'ap-northeast-2': 'arn:aws:lambda:ap-northeast-2:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'ap-south-1': 'arn:aws:lambda:ap-south-1:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'ap-southeast-1': 'arn:aws:lambda:ap-southeast-1:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'ap-southeast-2': 'arn:aws:lambda:ap-southeast-2:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'ca-central-1': 'arn:aws:lambda:ca-central-1:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'eu-central-1': 'arn:aws:lambda:eu-central-1:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'eu-north-1': 'arn:aws:lambda:eu-north-1:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'eu-west-1': 'arn:aws:lambda:eu-west-1:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'eu-west-2': 'arn:aws:lambda:eu-west-2:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'eu-west-3': 'arn:aws:lambda:eu-west-3:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'sa-east-1': 'arn:aws:lambda:sa-east-1:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'us-east-1': 'arn:aws:lambda:us-east-1:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'us-east-2': 'arn:aws:lambda:us-east-2:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'us-west-1': 'arn:aws:lambda:us-west-1:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + 'us-west-2': 'arn:aws:lambda:us-west-2:901920570463:layer:aws-otel-python-amd64-ver-1-15-0:2', + }, + arm64: { + 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'ap-northeast-2': 'arn:aws:lambda:ap-northeast-2:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'ap-south-1': 'arn:aws:lambda:ap-south-1:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'ap-southeast-1': 'arn:aws:lambda:ap-southeast-1:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'ap-southeast-2': 'arn:aws:lambda:ap-southeast-2:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'ca-central-1': 'arn:aws:lambda:ca-central-1:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'eu-central-1': 'arn:aws:lambda:eu-central-1:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'eu-north-1': 'arn:aws:lambda:eu-north-1:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'eu-west-1': 'arn:aws:lambda:eu-west-1:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'eu-west-2': 'arn:aws:lambda:eu-west-2:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'eu-west-3': 'arn:aws:lambda:eu-west-3:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'sa-east-1': 'arn:aws:lambda:sa-east-1:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'us-east-1': 'arn:aws:lambda:us-east-1:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'us-east-2': 'arn:aws:lambda:us-east-2:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'us-west-1': 'arn:aws:lambda:us-west-1:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + 'us-west-2': 'arn:aws:lambda:us-west-2:901920570463:layer:aws-otel-python-arm64-ver-1-15-0:2', + }, + }, '1.13.0': { x86_64: { 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-python-amd64-ver-1-13-0:1', @@ -673,6 +825,44 @@ const ADOT_LAMBDA_LAYER_PYTHON_SDK_ARNS: { [version: string]: { [arch: string]: }; const ADOT_LAMBDA_LAYER_GENERIC_ARNS: { [version: string]: { [arch: string]: { [region: string]: string } } } = { + '0.68.0': { + x86_64: { + 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'ap-northeast-2': 'arn:aws:lambda:ap-northeast-2:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'ap-south-1': 'arn:aws:lambda:ap-south-1:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'ap-southeast-1': 'arn:aws:lambda:ap-southeast-1:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'ap-southeast-2': 'arn:aws:lambda:ap-southeast-2:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'ca-central-1': 'arn:aws:lambda:ca-central-1:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'eu-central-1': 'arn:aws:lambda:eu-central-1:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'eu-north-1': 'arn:aws:lambda:eu-north-1:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'eu-west-1': 'arn:aws:lambda:eu-west-1:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'eu-west-2': 'arn:aws:lambda:eu-west-2:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'eu-west-3': 'arn:aws:lambda:eu-west-3:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'sa-east-1': 'arn:aws:lambda:sa-east-1:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'us-east-1': 'arn:aws:lambda:us-east-1:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'us-east-2': 'arn:aws:lambda:us-east-2:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'us-west-1': 'arn:aws:lambda:us-west-1:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + 'us-west-2': 'arn:aws:lambda:us-west-2:901920570463:layer:aws-otel-collector-amd64-ver-0-68-0:1', + }, + arm64: { + 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'ap-northeast-2': 'arn:aws:lambda:ap-northeast-2:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'ap-south-1': 'arn:aws:lambda:ap-south-1:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'ap-southeast-1': 'arn:aws:lambda:ap-southeast-1:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'ap-southeast-2': 'arn:aws:lambda:ap-southeast-2:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'ca-central-1': 'arn:aws:lambda:ca-central-1:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'eu-central-1': 'arn:aws:lambda:eu-central-1:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'eu-north-1': 'arn:aws:lambda:eu-north-1:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'eu-west-1': 'arn:aws:lambda:eu-west-1:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'eu-west-2': 'arn:aws:lambda:eu-west-2:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'eu-west-3': 'arn:aws:lambda:eu-west-3:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'sa-east-1': 'arn:aws:lambda:sa-east-1:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'us-east-1': 'arn:aws:lambda:us-east-1:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'us-east-2': 'arn:aws:lambda:us-east-2:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'us-west-1': 'arn:aws:lambda:us-west-1:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + 'us-west-2': 'arn:aws:lambda:us-west-2:901920570463:layer:aws-otel-collector-arm64-ver-0-68-0:1', + }, + }, '0.62.1': { x86_64: { 'ap-northeast-1': 'arn:aws:lambda:ap-northeast-1:901920570463:layer:aws-otel-collector-amd64-ver-0-62-1:1', diff --git a/packages/aws-cdk/.npmignore b/packages/aws-cdk/.npmignore index 7c198b16e73f8..2a474fe68b670 100644 --- a/packages/aws-cdk/.npmignore +++ b/packages/aws-cdk/.npmignore @@ -11,9 +11,6 @@ dist .LAST_BUILD *.snk -!test/integ/cli/**/*.js -!test/integ/run-wrappers/dist - *.tsbuildinfo jest.config.js @@ -24,10 +21,7 @@ tsconfig.json !lib/init-templates/**/tsconfig.json !lib/init-templates/**/jest.config.js -!test/integ/cli/jest.config.js -!test/integ/uberpackage/jest.config.js -!test/integ/cli-regression-patches/**/* -!test/integ/cli/sam_cdk_integ_app/**/*.ts +!test/integ/**/* .DS_Store diff --git a/packages/aws-cdk/lib/api/aws-auth/aws-sdk-inifile.ts b/packages/aws-cdk/lib/api/aws-auth/aws-sdk-inifile.ts index 330ea62665c55..0ff4d3980c0c1 100644 --- a/packages/aws-cdk/lib/api/aws-auth/aws-sdk-inifile.ts +++ b/packages/aws-cdk/lib/api/aws-auth/aws-sdk-inifile.ts @@ -7,24 +7,13 @@ import * as AWS from 'aws-sdk'; * There are a number of issues in the upstream version of SharedIniFileCredentials * that need fixing: * - * 1. The upstream aws-sdk contains an incorrect instantiation of an `AWS.STS` - * client, which *should* have taken the region from the requested profile - * but doesn't. It will use the region from the default profile, which - * may not exist, defaulting to `us-east-1` (since we switched to - * AWS_STS_REGIONAL_ENDPOINTS=regional, that default is not even allowed anymore - * and the absence of a default region will lead to an error). + * 1. The upstream aws-sdk does not support the 'credential_source' option. Meaning credentials + * for assume-role cannot be fetched using EC2/ESC metadata. * - * 2. The simple fix is to get the region from the `config` file. profiles - * are made up of a combination of `credentials` and `config`, and the region is - * generally in `config` with the rest in `credentials`. However, a bug in - * `getProfilesFromSharedConfig` overwrites ALL `config` data with `credentials` - * data, so we also need to do extra work to fish the `region` out of the config. - * - * 3. The 'credential_source' option is not supported. Meaning credentials - * for assume-role cannot be fetched using EC2/ESC metadata. - * - * See https://github.com/aws/aws-sdk-js/issues/3418 for all the gory details. - * See https://github.com/aws/aws-sdk-js/issues/1916 for some more glory details. + * 2. The upstream aws-sdk does not support SSO profiles as the source of RoleProfiles, + * because it will always use the `SharedIniFileCredentials` provider to load + * source credentials, but in order to support SSO profiles you must use a + * separate class (`SsoCredentials). */ export class PatchedSharedIniFileCredentials extends AWS.SharedIniFileCredentials { declare private profile: string; @@ -60,21 +49,29 @@ export class PatchedSharedIniFileCredentials extends AWS.SharedIniFileCredential var sourceProfile = roleProfile.source_profile; var credentialSource = roleProfile.credential_source; - const credentialError = (AWS as any).util.error( - new Error(`When using 'role_arn' in profile ('${this.profile}'), you must also configure exactly one of 'source_profile' or 'credential_source'`), - { code: 'SharedIniFileCredentialsProviderFailure' }, - ); - - if (sourceProfile && credentialSource) { - throw credentialError; - } - - if (!sourceProfile && !credentialSource) { - throw credentialError; + if (!!sourceProfile === !!credentialSource) { + throw (AWS as any).util.error( + new Error(`When using 'role_arn' in profile ('${this.profile}'), you must also configure exactly one of 'source_profile' or 'credential_source'`), + { code: 'SharedIniFileCredentialsProviderFailure' }, + ); } - const profiles = loadProfilesProper(this.filename); - const region = profiles[this.profile]?.region ?? profiles.default?.region ?? 'us-east-1'; + // Confirmed this against AWS CLI behavior -- the region must be in the assumED profile, + // otherwise `us-east-1`. From the upstream comment in `aws-sdk-js`: + // -------- comment from aws-sdk-js ------------------- + // Experimentation shows that the AWS CLI (tested at version 1.18.136) + // ignores the following potential sources of a region for the purposes of + // this AssumeRole call: + // + // - The [default] profile + // - The AWS_REGION environment variable + // + // Ignoring the [default] profile for the purposes of AssumeRole is arguably + // a bug in the CLI since it does use the [default] region for service + // calls... but right now we're matching behavior of the other tool. + // ------------------------------------------------- + + const region = roleProfile?.region ?? 'us-east-1'; const stsCreds = sourceProfile ? this.sourceProfileCredentials(sourceProfile, creds) : this.credentialSourceCredentials(credentialSource); @@ -121,7 +118,6 @@ export class PatchedSharedIniFileCredentials extends AWS.SharedIniFileCredential } private sourceProfileCredentials(sourceProfile: string, profiles: Record>) { - var sourceProfileExistanceTest = profiles[sourceProfile]; if (typeof sourceProfileExistanceTest !== 'object') { @@ -132,11 +128,23 @@ export class PatchedSharedIniFileCredentials extends AWS.SharedIniFileCredential ); } - if (sourceProfileExistanceTest.sso_start_url) { + // We need to do a manual check here if the source profile (providing the + // credentials for the AssumeRole) is an SSO profile. That's because + // `SharedIniFileCredentials` itself doesn't support providing credentials from + // arbitrary profiles, only for StaticCredentials and AssumeRole type + // profiles; if it's an SSO profile you need to instantiate a special + // Credential Provider for that. + // + // --- + // + // An SSO profile can be configured in 2 ways (put all the info in the profile + // section, or put half of it in an `[sso-session]` block), but in both cases + // the primary profile block must have the `sso_account_id` key + if (sourceProfileExistanceTest.sso_account_id) { return new AWS.SsoCredentials({ profile: sourceProfile }); } - return new AWS.SharedIniFileCredentials( + return new PatchedSharedIniFileCredentials( (AWS as any).util.merge(this.options || {}, { profile: sourceProfile, preferStaticCredentials: true, @@ -148,7 +156,6 @@ export class PatchedSharedIniFileCredentials extends AWS.SharedIniFileCredential // the aws-sdk for js does not support 'credential_source' (https://github.com/aws/aws-sdk-js/issues/1916) // so unfortunately we need to implement this ourselves. private credentialSourceCredentials(sourceCredential: string) { - // see https://docs.aws.amazon.com/credref/latest/refdocs/setting-global-credential_source.html switch (sourceCredential) { case 'Environment': { @@ -166,36 +173,4 @@ export class PatchedSharedIniFileCredentials extends AWS.SharedIniFileCredential } } -} - -/** - * A function to load profiles from disk that MERGES credentials and config instead of overwriting - * - * @see https://github.com/aws/aws-sdk-js/blob/5ae5a7d7d24d1000dbc089cc15f8ed2c7b06c542/lib/util.js#L956 - */ -function loadProfilesProper(filename: string) { - const util = (AWS as any).util; // Does exists even though there aren't any typings for it - const iniLoader = util.iniLoader; - const profiles: Record> = {}; - let profilesFromConfig: Record> = {}; - if (process.env[util.configOptInEnv]) { - profilesFromConfig = iniLoader.loadFrom({ - isConfig: true, - filename: process.env[util.sharedConfigFileEnv], - }); - } - var profilesFromCreds: Record> = iniLoader.loadFrom({ - filename: filename || - (process.env[util.configOptInEnv] && process.env[util.sharedCredentialsFileEnv]), - }); - for (const [name, profile] of Object.entries(profilesFromConfig)) { - profiles[name] = profile; - } - for (const [name, profile] of Object.entries(profilesFromCreds)) { - profiles[name] = { - ...profiles[name], - ...profile, - }; - } - return profiles; -} +} \ No newline at end of file diff --git a/packages/aws-cdk/lib/api/cxapp/exec.ts b/packages/aws-cdk/lib/api/cxapp/exec.ts index d4bb217135d59..d39e511d4cbbd 100644 --- a/packages/aws-cdk/lib/api/cxapp/exec.ts +++ b/packages/aws-cdk/lib/api/cxapp/exec.ts @@ -11,9 +11,15 @@ import { loadTree, some } from '../../tree'; import { splitBySize } from '../../util/objects'; import { versionNumber } from '../../version'; import { SdkProvider } from '../aws-auth'; +import { RWLock, ILock } from '../util/rwlock'; + +export interface ExecProgramResult { + readonly assembly: cxapi.CloudAssembly; + readonly lock: ILock; +} /** Invokes the cloud executable and returns JSON output */ -export async function execProgram(aws: SdkProvider, config: Configuration): Promise { +export async function execProgram(aws: SdkProvider, config: Configuration): Promise { const env: { [key: string]: string } = { }; const context = config.context.all; @@ -62,7 +68,11 @@ export async function execProgram(aws: SdkProvider, config: Configuration): Prom // bypass "synth" if app points to a cloud assembly if (await fs.pathExists(app) && (await fs.stat(app)).isDirectory()) { debug('--app points to a cloud assembly, so we bypass synth'); - return createAssembly(app); + + // Acquire a read lock on this directory + const lock = await new RWLock(app).acquireRead(); + + return { assembly: createAssembly(app), lock }; } const commandLine = await guessExecutable(appToArray(app)); @@ -80,6 +90,9 @@ export async function execProgram(aws: SdkProvider, config: Configuration): Prom debug('outdir:', outdir); env[cxapi.OUTDIR_ENV] = outdir; + // Acquire a read lock on the output directory + const writerLock = await new RWLock(outdir).acquireWrite(); + // Send version information env[cxapi.CLI_ASM_VERSION_ENV] = cxschema.Manifest.version(); env[cxapi.CLI_VERSION_ENV] = versionNumber(); @@ -107,7 +120,7 @@ export async function execProgram(aws: SdkProvider, config: Configuration): Prom contextOverflowCleanup(contextOverflowLocation, assembly); - return assembly; + return { assembly, lock: await writerLock.convertToReaderLock() }; function createAssembly(appDir: string) { try { diff --git a/packages/aws-cdk/lib/api/util/rwlock.ts b/packages/aws-cdk/lib/api/util/rwlock.ts new file mode 100644 index 0000000000000..6667bd17afe06 --- /dev/null +++ b/packages/aws-cdk/lib/api/util/rwlock.ts @@ -0,0 +1,184 @@ +import { promises as fs } from 'fs'; +import * as path from 'path'; + +/** + * A single-writer/multi-reader lock on a directory + * + * It uses marker files with PIDs in them as a locking marker; the PIDs will be + * checked for liveness, so that if the process exits without cleaning up the + * files the lock is implicitly released. + * + * This class is not 100% race safe, but in practice it should be a lot + * better than the 0 protection we have today. + */ +export class RWLock { + private readonly pidString: string; + private readonly writerFile: string; + private readonly readerFile: string; + + constructor(public readonly directory: string) { + this.pidString = `${process.pid}`; + + this.writerFile = path.join(this.directory, 'synth.lock'); + this.readerFile = path.join(this.directory, `read.${this.pidString}.lock`); + } + + /** + * Acquire a writer lock. + * + * No other readers or writers must exist for the given directory. + */ + public async acquireWrite(): Promise { + await this.assertNoOtherWriters(); + + const readers = await this.currentReaders(); + if (readers.length > 0) { + throw new Error(`Other CLIs (PID=${readers}) are currently reading from ${this.directory}. Invoke the CLI in sequence, or use '--output' to synth into different directories.`); + } + + await writeFileAtomic(this.writerFile, this.pidString); + + return { + release: async () => { + await deleteFile(this.writerFile); + }, + convertToReaderLock: async () => { + // Acquire the read lock before releasing the write lock. Slightly less + // chance of racing! + const ret = await this.doAcquireRead(); + await deleteFile(this.writerFile); + return ret; + }, + }; + } + + /** + * Acquire a read lock + * + * Will fail if there are any writers. + */ + public async acquireRead(): Promise { + await this.assertNoOtherWriters(); + return this.doAcquireRead(); + } + + /** + * Do the actual acquiring of a read lock. + */ + private async doAcquireRead(): Promise { + await writeFileAtomic(this.readerFile, this.pidString); + return { + release: async () => { + await deleteFile(this.readerFile); + }, + }; + } + + private async assertNoOtherWriters() { + const writer = await this.currentWriter(); + if (writer) { + throw new Error(`Another CLI (PID=${writer}) is currently synthing to ${this.directory}. Invoke the CLI in sequence, or use '--output' to synth into different directories.`); + } + } + + /** + * Check the current writer (if any) + */ + private async currentWriter(): Promise { + const contents = await readFileIfExists(this.writerFile); + if (!contents) { return undefined; } + + const pid = parseInt(contents, 10); + if (!processExists(pid)) { + // Do cleanup of a stray file now + await deleteFile(this.writerFile); + return undefined; + } + + return pid; + } + + /** + * Check the current readers (if any) + */ + private async currentReaders(): Promise { + const re = /^read\.([^.]+)\.lock$/; + const ret = new Array(); + + let children; + try { + children = await fs.readdir(this.directory, { encoding: 'utf-8' }); + } catch (e) { + // Can't be locked if the directory doesn't exist + if (e.code === 'ENOENT') { return []; } + throw e; + } + + for (const fname of children) { + const m = fname.match(re); + if (m) { + const pid = parseInt(m[1], 10); + if (processExists(pid)) { + ret.push(pid); + } else { + // Do cleanup of a stray file now + await deleteFile(path.join(this.directory, fname)); + } + } + } + return ret; + } +} + +/** + * An acquired lock + */ +export interface ILock { + release(): Promise; +} + +/** + * An acquired writer lock + */ +export interface IWriterLock extends ILock { + /** + * Convert the writer lock to a reader lock + */ + convertToReaderLock(): Promise; +} + +async function readFileIfExists(filename: string): Promise { + try { + return await fs.readFile(filename, { encoding: 'utf-8' }); + } catch (e) { + if (e.code === 'ENOENT') { return undefined; } + throw e; + } +} + +async function writeFileAtomic(filename: string, contents: string): Promise { + await fs.mkdir(path.dirname(filename), { recursive: true }); + const tmpFile = `${filename}.${process.pid}`; + await fs.writeFile(tmpFile, contents, { encoding: 'utf-8' }); + await fs.rename(tmpFile, filename); +} + +async function deleteFile(filename: string) { + try { + await fs.unlink(filename); + } catch (e) { + if (e.code === 'ENOENT') { + return; + } + throw e; + } +} + +function processExists(pid: number) { + try { + process.kill(pid, 0); + return true; + } catch (e) { + return false; + } +} \ No newline at end of file diff --git a/packages/aws-cdk/lib/cli.ts b/packages/aws-cdk/lib/cli.ts index 32dfb3e0dc32f..c38bee7f7f26d 100644 --- a/packages/aws-cdk/lib/cli.ts +++ b/packages/aws-cdk/lib/cli.ts @@ -24,8 +24,9 @@ import { displayNotices, refreshNotices } from '../lib/notices'; import { Command, Configuration, Settings } from '../lib/settings'; import * as version from '../lib/version'; import { DeploymentMethod } from './api'; -import { enableTracing } from './util/tracing'; +import { ILock } from './api/util/rwlock'; import { checkForPlatformWarnings } from './platform-warnings'; +import { enableTracing } from './util/tracing'; // https://github.com/yargs/yargs/issues/1929 // https://github.com/evanw/esbuild/issues/1492 @@ -329,10 +330,19 @@ async function initCommandLine() { const cloudFormation = new CloudFormationDeployments({ sdkProvider }); + let outDirLock: ILock | undefined; const cloudExecutable = new CloudExecutable({ configuration, sdkProvider, - synthesizer: execProgram, + synthesizer: async (aws, config) => { + // Invoke 'execProgram', and copy the lock for the directory in the global + // variable here. It will be released when the CLI exits. Locks are not re-entrant + // so release it if we have to synthesize more than once (because of context lookups). + await outDirLock?.release(); + const { assembly, lock } = await execProgram(aws, config); + outDirLock = lock; + return assembly; + }, }); /** Function to load plug-ins, using configurations additively. */ @@ -373,6 +383,10 @@ async function initCommandLine() { try { return await main(cmd, argv); } finally { + // If we locked the 'cdk.out' directory, release it here. + await outDirLock?.release(); + + // Do PSAs here await version.displayVersionMessage(); if (shouldDisplayNotices()) { diff --git a/packages/aws-cdk/test/api/exec.test.ts b/packages/aws-cdk/test/api/exec.test.ts index b9c5637acce1a..e52b4485da2cd 100644 --- a/packages/aws-cdk/test/api/exec.test.ts +++ b/packages/aws-cdk/test/api/exec.test.ts @@ -90,7 +90,8 @@ test('cli does not throw when manifest version = schema version', async () => { config.settings.set(['app'], 'cdk.out'); - await execProgram(sdkProvider, config); + const { lock } = await execProgram(sdkProvider, config); + await lock.release(); }, TEN_SECOND_TIMEOUT); @@ -107,7 +108,8 @@ test('cli does not throw when manifest version < schema version', async () => { // greater that the version created in the manifest, which is what we are testing for. const mockVersionNumber = ImportMock.mockFunction(cxschema.Manifest, 'version', semver.inc(currentSchemaVersion, 'major')); try { - await execProgram(sdkProvider, config); + const { lock } = await execProgram(sdkProvider, config); + await lock.release(); } finally { mockVersionNumber.restore(); } @@ -128,9 +130,11 @@ test('bypasses synth when app points to a cloud assembly', async () => { writeOutputAssembly(); // WHEN - const cloudAssembly = await execProgram(sdkProvider, config); + const { assembly: cloudAssembly, lock } = await execProgram(sdkProvider, config); expect(cloudAssembly.artifacts).toEqual([]); expect(cloudAssembly.directory).toEqual('cdk.out'); + + await lock.release(); }); test('the application set in --app is executed', async () => { @@ -142,7 +146,8 @@ test('the application set in --app is executed', async () => { }); // WHEN - await execProgram(sdkProvider, config); + const { lock } = await execProgram(sdkProvider, config); + await lock.release(); }); test('the application set in --app is executed as-is if it contains a filename that does not exist', async () => { @@ -154,7 +159,8 @@ test('the application set in --app is executed as-is if it contains a filename t }); // WHEN - await execProgram(sdkProvider, config); + const { lock } = await execProgram(sdkProvider, config); + await lock.release(); }); test('the application set in --app is executed with arguments', async () => { @@ -166,7 +172,8 @@ test('the application set in --app is executed with arguments', async () => { }); // WHEN - await execProgram(sdkProvider, config); + const { lock } = await execProgram(sdkProvider, config); + await lock.release(); }); test('application set in --app as `*.js` always uses handler on windows', async () => { @@ -179,7 +186,8 @@ test('application set in --app as `*.js` always uses handler on windows', async }); // WHEN - await execProgram(sdkProvider, config); + const { lock } = await execProgram(sdkProvider, config); + await lock.release(); }); test('application set in --app is `*.js` and executable', async () => { @@ -191,7 +199,8 @@ test('application set in --app is `*.js` and executable', async () => { }); // WHEN - await execProgram(sdkProvider, config); + const { lock } = await execProgram(sdkProvider, config); + await lock.release(); }); test('cli throws when the `build` script fails', async () => { @@ -220,7 +229,8 @@ test('cli does not throw when the `build` script succeeds', async () => { }); // WHEN - await execProgram(sdkProvider, config); + const { lock } = await execProgram(sdkProvider, config); + await lock.release(); }, TEN_SECOND_TIMEOUT); diff --git a/packages/aws-cdk/test/api/logs/logs-monitor.test.ts b/packages/aws-cdk/test/api/logs/logs-monitor.test.ts index eed3cf2683540..7f5e54a89b300 100644 --- a/packages/aws-cdk/test/api/logs/logs-monitor.test.ts +++ b/packages/aws-cdk/test/api/logs/logs-monitor.test.ts @@ -1,6 +1,6 @@ import { blue, yellow } from 'chalk'; import { CloudWatchLogEventMonitor } from '../../../lib/api/logs/logs-monitor'; -import { sleep } from '../../integ/helpers/aws'; +import { sleep } from '../../util'; import { MockSdk } from '../../util/mock-sdk'; let sdk: MockSdk; diff --git a/packages/aws-cdk/test/integ/cli-regression-patches/README.md b/packages/aws-cdk/test/integ/cli-regression-patches/README.md deleted file mode 100644 index c930255e85809..0000000000000 --- a/packages/aws-cdk/test/integ/cli-regression-patches/README.md +++ /dev/null @@ -1,54 +0,0 @@ -Regression Test Patches -======================== - -The regression test suite will use the test suite of an OLD version -of the CLI when testing a NEW version of the CLI, to make sure the -old tests still pass. - -Sometimes though, the old tests won't pass. This can happen when we -introduce breaking changes to the framework or CLI (for something serious, -such as security reasons), or maybe because we had a bug in an old -version that happened to pass, but now the test needs to be updated -in order to pass a bugfix. - -## Mechanism - -The files in this directory will be copied over the test directory -so that you can exclude tests from running, or patch up test running -scripts. - -Files will be copied like so: - -``` -aws-cdk/test/integ/cli-regression-patches/vX.Y.Z/* - -# will be copied into - -aws-cdk/test/integ/cli -``` - -For example, to skip a certain integration test during regression -testing, create the following file: - -``` -cli-regression-patches/vX.Y.Z/skip-tests.txt -``` - -If you need to replace source files, it's probably best to stick -compiled `.js` files in here. `.ts` source files wouldn't compile -because they'd be missing `imports`. - -## Versioning - -The patch sets are versioned, so that they will only be applied for -a certain version of the tests and will automatically age out when -we proceed past that release. - -The version in the directory name needs to be named after the -version that contains the *tests* we're running, that need to be -patched. - -So for example, if we are running regression tests for release -candidate `1.45.0`, we would use the tests from released version -`1.44.0`, and so you would call the patch directory `v1.44.0`. - diff --git a/packages/aws-cdk/test/integ/cli/jest.config.js b/packages/aws-cdk/test/integ/cli/jest.config.js deleted file mode 100644 index 1e3fe3d13f96b..0000000000000 --- a/packages/aws-cdk/test/integ/cli/jest.config.js +++ /dev/null @@ -1,15 +0,0 @@ -module.exports = { - moduleFileExtensions: [ - "js", - ], - testMatch: [ - "**/*.integtest.js", - ], - testEnvironment: "node", - bail: 1, - verbose: true, - reporters: [ - "default", - [ "jest-junit", { suiteName: "jest tests", outputDirectory: "coverage" } ] - ] -}; diff --git a/packages/aws-cdk/test/integ/cli/test.sh b/packages/aws-cdk/test/integ/cli/test.sh index bf0ec0a7c5c68..1d33ee1502bbd 100755 --- a/packages/aws-cdk/test/integ/cli/test.sh +++ b/packages/aws-cdk/test/integ/cli/test.sh @@ -1,12 +1,6 @@ #!/bin/bash -set -euo pipefail -scriptdir=$(cd $(dirname $0) && pwd) +set -eu +# This is a backwards compatibility script. All logic has moved to '@aws-cdk-testing/cli-integ' +# and should be called from there directly. -echo '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~' -echo 'CLI Integration Tests' -echo '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~' - -cd $scriptdir - -source ../common/jest-test.bash -invokeJest "$@" +exec ${INTEG_TOOLS}/bin/run-suite --use-cli-release=$VERSION cli-integ-tests diff --git a/packages/aws-cdk/test/integ/common/jest-test.bash b/packages/aws-cdk/test/integ/common/jest-test.bash deleted file mode 100755 index 7a96a9f845155..0000000000000 --- a/packages/aws-cdk/test/integ/common/jest-test.bash +++ /dev/null @@ -1,18 +0,0 @@ -function invokeJest() { - # Install these dependencies that the tests (written in Jest) need. - # Only if we're not running from the repo, because if we are the - # dependencies have already been installed by the containing 'aws-cdk' package's - # package.json. - if ! npx --no-install jest --version; then - echo 'Looks like we need to install jest first. Hold on.' >& 2 - npm install --prefix .. jest@^27 jest-junit@^14 aws-sdk@^2 axios@^0.27.2 - fi - - # This must --runInBand because parallelism is arranged for inside the tests - # themselves and they must run in the same process in order to coordinate to - # make sure no 2 tests use the same region at the same time. - # - # Jest is run in a weird way because npx started (NPM 8?) to change directory - # into 'package.json' root, which we don't want here. - $(npx which jest) --runInBand --verbose "$@" -} diff --git a/packages/aws-cdk/test/integ/github-helpers.ts b/packages/aws-cdk/test/integ/github-helpers.ts deleted file mode 100644 index d5a9b6cb41df7..0000000000000 --- a/packages/aws-cdk/test/integ/github-helpers.ts +++ /dev/null @@ -1,38 +0,0 @@ -import { Octokit } from '@octokit/rest'; -import * as semver from 'semver'; - -module.exports.fetchPreviousVersion = async function(base: string) { - const token = process.env.GITHUB_TOKEN; - if (!token) { - throw new Error('GITHUB_TOKEN must be set'); - } - - const github = new Octokit({ auth: token }); - const releases = await github.repos.listReleases({ - owner: 'aws', - repo: 'aws-cdk', - }); - - // this returns a list in descending order, newest releases first - // opts for same major version where possible, falling back otherwise - // to previous major versions. - let previousMVRelease = undefined; - for (const release of releases.data) { - const version = release.name?.replace('v', ''); - if (version && semver.lt(version, base)) { - if (semver.major(version) === semver.major(base)) { - return version; - } else if (!previousMVRelease) { - previousMVRelease = version; - } - } - } - if (previousMVRelease) { return previousMVRelease; } - - throw new Error(`Unable to find previous version of ${base}`); -}; - -// eslint-disable-next-line @typescript-eslint/no-require-imports -require('make-runnable/custom')({ - printOutputFrame: false, -}); diff --git a/packages/aws-cdk/test/integ/helpers/resource-pool.test.ts b/packages/aws-cdk/test/integ/helpers/resource-pool.test.ts deleted file mode 100644 index edae1a1ed170a..0000000000000 --- a/packages/aws-cdk/test/integ/helpers/resource-pool.test.ts +++ /dev/null @@ -1,47 +0,0 @@ -import { ResourcePool } from './resource-pool'; - -test('take and dispose', async () => { - const pool = new ResourcePool(['a']); - - const take1 = pool.take(); - const take2 = pool.take(); - - let released = false; - - const lease1 = await take1; - // awaiting 'take2' would now block but we add an async - // handler to it to flip a boolean to see when it gets activated. - void(take2.then(() => released = true)); - - expect(lease1.value).toEqual('a'); - await waitTick(); - expect(released).toEqual(false); - - lease1.dispose(); - await waitTick(); // This works because setImmediate is scheduled in LIFO order - expect(released).toEqual(true); -}); - -test('double dispose throws', async () => { - const pool = new ResourcePool(['a']); - const lease = await pool.take(); - - lease.dispose(); - expect(() => lease.dispose()).toThrow(); -}); - -test('more consumers than values', async () => { - const pool = new ResourcePool(['a', 'b']); - - const values = await Promise.all([ - pool.using(x => x), - pool.using(x => x), - pool.using(x => x), - ]); - - expect(values).toEqual(['a', 'b', 'a']); -}); - -function waitTick() { - return new Promise(setImmediate); -} \ No newline at end of file diff --git a/packages/aws-cdk/test/integ/helpers/resource-pool.ts b/packages/aws-cdk/test/integ/helpers/resource-pool.ts deleted file mode 100644 index 444a0bc193edd..0000000000000 --- a/packages/aws-cdk/test/integ/helpers/resource-pool.ts +++ /dev/null @@ -1,95 +0,0 @@ -/** - * A class that holds a pool of resources and gives them out and returns them on-demand - * - * The resources will be given out front to back, when they are returned - * the most recently returned version will be given out again (for best - * cache coherency). - * - * If there are multiple consumers waiting for a resource, consumers are serviced - * in FIFO order for most fairness. - */ -export class ResourcePool { - private readonly resources: A[]; - private readonly waiters: Array<(x: A) => void> = []; - - constructor(resources: A[]) { - if (resources.length === 0) { - throw new Error('Must have at least one resource in the pool'); - } - this.resources = [...resources]; - } - - /** - * Take one value from the resource pool - * - * If no such value is currently available, wait until it is. - */ - public take(): Promise> { - const next = this.resources.shift(); - if (next !== undefined) { - return Promise.resolve(this.makeLease(next)); - } else { - return new Promise(ok => { - this.waiters.push((resource) => ok(this.makeLease(resource))); - }); - } - } - - /** - * Execute a block using a single resource from the pool - */ - public async using(block: (x: A) => B | Promise): Promise { - const lease = await this.take(); - try { - return await block(lease.value); - } finally { - lease.dispose(); - } - } - - private makeLease(value: A): ILease { - let disposed = false; - return { - value, - dispose: () => { - if (disposed) { - throw new Error('Calling dispose() on an already-disposed lease.'); - } - disposed = true; - this.returnValue(value); - }, - }; - } - - /** - * When a value is returned: - * - * - If someone's waiting for it, give it to them - * - Otherwise put it back into the pool - */ - private returnValue(value: A) { - const nextWaiter = this.waiters.shift(); - if (nextWaiter !== undefined) { - // Execute in the next tick, otherwise the call stack is going to get very - // confusing. - setImmediate(() => nextWaiter(value)); - } else { - this.resources.unshift(value); - } - } -} - -/** - * A single value taken from the pool - */ -export interface ILease { - /** - * The value obtained by the lease - */ - readonly value: A; - - /** - * Return the leased value to the pool - */ - dispose(): void; -} \ No newline at end of file diff --git a/packages/aws-cdk/test/integ/init/common.bash b/packages/aws-cdk/test/integ/init/common.bash deleted file mode 100644 index f41f02b5215e8..0000000000000 --- a/packages/aws-cdk/test/integ/init/common.bash +++ /dev/null @@ -1,25 +0,0 @@ -set -eu -init_test_dir="${init_test_dir:=/tmp/cdk-init-test}" - -function setup() { - rm -rf $init_test_dir - mkdir -p $init_test_dir - cd $init_test_dir -} - -function log() { - echo >&2 "| $@" -} - -function header() { - log - log "============================================================================================" - log $@ - log "============================================================================================" -} - -function assert_no_hook_files() { - compgen "\*.hook.\*" || return 0 - echo "'cdk init' left hook files in the template directory!" >&2 - exit 1 -} diff --git a/packages/aws-cdk/test/integ/init/test-all.sh b/packages/aws-cdk/test/integ/init/test-all.sh deleted file mode 100755 index f191d37bf4296..0000000000000 --- a/packages/aws-cdk/test/integ/init/test-all.sh +++ /dev/null @@ -1,12 +0,0 @@ -#!/bin/bash -set -eu -scriptdir=$(cd $(dirname $0) && pwd) -$scriptdir/test-csharp.sh -$scriptdir/test-fsharp.sh -$scriptdir/test-java.sh -$scriptdir/test-javascript.sh -$scriptdir/test-python.sh -$scriptdir/test-typescript.sh -$scriptdir/test-go.sh - -echo "SUCCESS" diff --git a/packages/aws-cdk/test/integ/init/test-csharp-app.sh b/packages/aws-cdk/test/integ/init/test-csharp-app.sh index 19bd5c91e4ef9..c32d86b7ffbd8 100755 --- a/packages/aws-cdk/test/integ/init/test-csharp-app.sh +++ b/packages/aws-cdk/test/integ/init/test-csharp-app.sh @@ -1,6 +1,6 @@ #!/bin/bash -# Naming shim for backwards compatibility with legacy -# tests and canaries. set -eu -scriptdir=$(cd $(dirname $0) && pwd) -exec $scriptdir/test-csharp.sh +# This is a backwards compatibility script. All logic has moved to '@aws-cdk-testing/cli-integ' +# and should be called from there directly. + +exec ${INTEG_TOOLS}/bin/run-suite --use-cli-release=$VERSION init-csharp diff --git a/packages/aws-cdk/test/integ/init/test-csharp.sh b/packages/aws-cdk/test/integ/init/test-csharp.sh deleted file mode 100755 index ea82e3b63f38c..0000000000000 --- a/packages/aws-cdk/test/integ/init/test-csharp.sh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/bash -#------------------------------------------------------------------ -# setup -#------------------------------------------------------------------ -set -e -scriptdir=$(cd $(dirname $0) && pwd) -source ${scriptdir}/common.bash - -header C# - -#------------------------------------------------------------------ - -if [[ "${1:-}" == "" ]]; then - templates="app sample-app" -else - templates="$@" -fi - -for template in $templates; do - echo "Trying C# template $template" - - setup - - cdk init -l csharp $template - cdk synth -done diff --git a/packages/aws-cdk/test/integ/init/test-fsharp.sh b/packages/aws-cdk/test/integ/init/test-fsharp.sh index f8ad463703672..7ea578e300c8d 100755 --- a/packages/aws-cdk/test/integ/init/test-fsharp.sh +++ b/packages/aws-cdk/test/integ/init/test-fsharp.sh @@ -1,26 +1,6 @@ #!/bin/bash -#------------------------------------------------------------------ -# setup -#------------------------------------------------------------------ -set -e -scriptdir=$(cd $(dirname $0) && pwd) -source ${scriptdir}/common.bash +set -eu +# This is a backwards compatibility script. All logic has moved to '@aws-cdk-testing/cli-integ' +# and should be called from there directly. -header F# - -#------------------------------------------------------------------ - -if [[ "${1:-}" == "" ]]; then - templates="app sample-app" -else - templates="$@" -fi - -for template in $templates; do - echo "Trying F# template $template" - - setup - - cdk init -l fsharp $template - cdk synth -done +exec ${INTEG_TOOLS}/bin/run-suite --use-cli-release=$VERSION init-fsharp diff --git a/packages/aws-cdk/test/integ/init/test-generate-only.sh b/packages/aws-cdk/test/integ/init/test-generate-only.sh deleted file mode 100755 index f09ab29fcf537..0000000000000 --- a/packages/aws-cdk/test/integ/init/test-generate-only.sh +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/bash -#------------------------------------------------------------------ -# setup -#------------------------------------------------------------------ -set -e -scriptdir=$(cd $(dirname $0) && pwd) -source ${scriptdir}/common.bash - -header "--generate-only" - -#------------------------------------------------------------------ - -echo "Trying --generate-only" - -setup - -cdk init -l javascript --generate-only - -if [ -d .git ] -then - fail "git shouldn't have been initialized" -fi diff --git a/packages/aws-cdk/test/integ/init/test-go.sh b/packages/aws-cdk/test/integ/init/test-go.sh deleted file mode 100755 index 58959855073f0..0000000000000 --- a/packages/aws-cdk/test/integ/init/test-go.sh +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/bash -#------------------------------------------------------------------ -# setup -#------------------------------------------------------------------ -set -eu -scriptdir=$(cd $(dirname $0) && pwd) -source ${scriptdir}/common.bash -dist_root=$(cd ${DIST_ROOT:-.} && pwd) - -header Go - -#------------------------------------------------------------------ - -if [[ "${1:-}" == "" ]]; then - templates="app sample-app" -else - templates="$@" -fi - -for template in $templates; do - echo "Trying Go template $template" - - setup - - cdk init -l go $template - go mod edit -replace github.com/aws/aws-cdk-go/awscdk=$dist_root/go/awscdk - go mod tidy - go test - cdk synth -done diff --git a/packages/aws-cdk/test/integ/init/test-java.sh b/packages/aws-cdk/test/integ/init/test-java.sh index d2c95984fb178..404256230b64f 100755 --- a/packages/aws-cdk/test/integ/init/test-java.sh +++ b/packages/aws-cdk/test/integ/init/test-java.sh @@ -1,27 +1,6 @@ #!/bin/bash -#------------------------------------------------------------------ -# setup -#------------------------------------------------------------------ -set -e -scriptdir=$(cd $(dirname $0) && pwd) -source ${scriptdir}/common.bash +set -eu +# This is a backwards compatibility script. All logic has moved to '@aws-cdk-testing/cli-integ' +# and should be called from there directly. -header Java - -#------------------------------------------------------------------ - -if [[ "${1:-}" == "" ]]; then - templates="app sample-app" -else - templates="$@" -fi - -for template in $templates; do - echo "Trying Java template $template" - - setup - - cdk init -l java $template - mvn package - cdk synth -done +exec ${INTEG_TOOLS}/bin/run-suite --use-cli-release=$VERSION init-java diff --git a/packages/aws-cdk/test/integ/init/test-javascript.sh b/packages/aws-cdk/test/integ/init/test-javascript.sh index 511403e19efcd..8a544ff669ace 100755 --- a/packages/aws-cdk/test/integ/init/test-javascript.sh +++ b/packages/aws-cdk/test/integ/init/test-javascript.sh @@ -1,27 +1,6 @@ #!/bin/bash -#------------------------------------------------------------------ -# setup -#------------------------------------------------------------------ -set -e -scriptdir=$(cd $(dirname $0) && pwd) -source ${scriptdir}/common.bash +set -eu +# This is a backwards compatibility script. All logic has moved to '@aws-cdk-testing/cli-integ' +# and should be called from there directly. -header Javascript - -#------------------------------------------------------------------ - -if [[ "${1:-}" == "" ]]; then - templates="app sample-app" -else - templates="$@" -fi - -for template in $templates; do - echo "Trying Javascript template $template" - - setup - - cdk init -l javascript $template - npm run test - cdk synth -done +exec ${INTEG_TOOLS}/bin/run-suite --use-cli-release=$VERSION init-javascript diff --git a/packages/aws-cdk/test/integ/init/test-python-app.sh b/packages/aws-cdk/test/integ/init/test-python-app.sh index 3f130fcb24aaa..a6cb2be1f3af8 100755 --- a/packages/aws-cdk/test/integ/init/test-python-app.sh +++ b/packages/aws-cdk/test/integ/init/test-python-app.sh @@ -1,6 +1,6 @@ #!/bin/bash -# Naming shim for backwards compatibility with legacy -# tests and canaries. set -eu -scriptdir=$(cd $(dirname $0) && pwd) -exec $scriptdir/test-python.sh +# This is a backwards compatibility script. All logic has moved to '@aws-cdk-testing/cli-integ' +# and should be called from there directly. + +exec ${INTEG_TOOLS}/bin/run-suite --use-cli-release=$VERSION init-python diff --git a/packages/aws-cdk/test/integ/init/test-python-stackname.sh b/packages/aws-cdk/test/integ/init/test-python-stackname.sh deleted file mode 100755 index 415c9bdb25cf2..0000000000000 --- a/packages/aws-cdk/test/integ/init/test-python-stackname.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/bash -# Naming shim for backwards compatibility with legacy -# tests and canaries. -set -eu -scriptdir=$(cd $(dirname $0) && pwd) -init_test_dir=/tmp/cdkInitTest -source $scriptdir/test-python.sh diff --git a/packages/aws-cdk/test/integ/init/test-python.sh b/packages/aws-cdk/test/integ/init/test-python.sh deleted file mode 100755 index d40d94d4534ca..0000000000000 --- a/packages/aws-cdk/test/integ/init/test-python.sh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/bash -#------------------------------------------------------------------ -# setup -#------------------------------------------------------------------ -set -eu -scriptdir=$(cd $(dirname $0) && pwd) -source ${scriptdir}/common.bash - -header Python - -#------------------------------------------------------------------ - -if [[ "${1:-}" == "" ]]; then - templates="app sample-app" -else - templates="$@" -fi - -for template in $templates; do - echo "Trying Python template $template" - - setup - - cdk init -l python $template - - source .venv/bin/activate - type -p pip - pip install -r requirements.txt - ./.venv/bin/pip install -r requirements-dev.txt - pytest - - cdk synth -done diff --git a/packages/aws-cdk/test/integ/init/test-typescript-app.sh b/packages/aws-cdk/test/integ/init/test-typescript-app.sh index 7db05ee7e5dad..68ff7bc6f5b2c 100755 --- a/packages/aws-cdk/test/integ/init/test-typescript-app.sh +++ b/packages/aws-cdk/test/integ/init/test-typescript-app.sh @@ -1,7 +1,6 @@ #!/bin/bash -# Naming shim for backwards compatibility with legacy -# tests and canaries. set -eu -scriptdir=$(cd $(dirname $0) && pwd) -# Run both app templates -exec $scriptdir/test-typescript.sh app sample-app +# This is a backwards compatibility script. All logic has moved to '@aws-cdk-testing/cli-integ' +# and should be called from there directly. + +exec ${INTEG_TOOLS}/bin/run-suite --use-cli-release=$VERSION init-typescript-app diff --git a/packages/aws-cdk/test/integ/init/test-typescript-lib.sh b/packages/aws-cdk/test/integ/init/test-typescript-lib.sh index 514f6bf9fb800..7bae427df1e66 100755 --- a/packages/aws-cdk/test/integ/init/test-typescript-lib.sh +++ b/packages/aws-cdk/test/integ/init/test-typescript-lib.sh @@ -1,7 +1,6 @@ #!/bin/bash -# Naming shim for backwards compatibility with legacy -# tests and canaries. set -eu -scriptdir=$(cd $(dirname $0) && pwd) -# Run only lib template -exec $scriptdir/test-typescript.sh lib +# This is a backwards compatibility script. All logic has moved to '@aws-cdk-testing/cli-integ' +# and should be called from there directly. + +exec ${INTEG_TOOLS}/bin/run-suite --use-cli-release=$VERSION init-typescript-lib diff --git a/packages/aws-cdk/test/integ/init/test-typescript-versions.sh b/packages/aws-cdk/test/integ/init/test-typescript-versions.sh index da5793661a97e..33b52b062070b 100755 --- a/packages/aws-cdk/test/integ/init/test-typescript-versions.sh +++ b/packages/aws-cdk/test/integ/init/test-typescript-versions.sh @@ -3,34 +3,7 @@ # setup #------------------------------------------------------------------ set -eu -scriptdir=$(cd $(dirname $0) && pwd) -integdir=$(dirname $scriptdir) -source ${scriptdir}/common.bash -header TypeScript Versions - -#------------------------------------------------------------------ - -MIN_SUPPORTED_TS_VERSION=${1:-"3.9"} -SUPPORTED_TS_VERSIONS=$(node ${integdir}/typescript-versions.js ${MIN_SUPPORTED_TS_VERSION}) - -for version in $SUPPORTED_TS_VERSIONS; do - header TypeScript v$version - - setup - - set -x - node --version - npm --version - - cdk init -l typescript sample-app --generate-only - sed '/\"devDependencies\"/,/}/ d; /^$/d' package.json > package.json.new && rm package.json && mv package.json.new package.json - npm install --save-dev typescript@$version - npm install # Older versions of npm require this to be a separate step from the one above - npm prune && npm ls - rm test/* - npm run build - cdk synth - - set +x -done +# This is a backwards compatibility script. All logic has moved to '@aws-cdk-testing/cli-integ', +# and in fact has been integrated into the regular TypeScript tests. +exit 0 \ No newline at end of file diff --git a/packages/aws-cdk/test/integ/init/test-typescript.sh b/packages/aws-cdk/test/integ/init/test-typescript.sh deleted file mode 100755 index 14fa77d4463dd..0000000000000 --- a/packages/aws-cdk/test/integ/init/test-typescript.sh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/bash -#------------------------------------------------------------------ -# setup -#------------------------------------------------------------------ -set -eu -scriptdir=$(cd $(dirname $0) && pwd) -source ${scriptdir}/common.bash - -header TypeScript - -#------------------------------------------------------------------ - -if [[ "${1:-}" == "" ]]; then - templates="app sample-app lib" -else - templates="$@" -fi - -for template in $templates; do - echo "Trying TypeScript template $template" - - setup - - cdk init -l typescript $template - npm prune && npm ls # this will fail if we have unmet peer dependencies - npm run build - npm run test - - # Can't run `cdk synth` on libraries - if [[ $template != "lib" ]]; then - cdk synth - fi -done diff --git a/packages/aws-cdk/test/integ/run-against-dist b/packages/aws-cdk/test/integ/run-against-dist index c7ade80dbb1f3..5fb4abea341eb 100755 --- a/packages/aws-cdk/test/integ/run-against-dist +++ b/packages/aws-cdk/test/integ/run-against-dist @@ -1,48 +1,19 @@ #!/bin/bash -# Run a given test against the packages found in the CDK distribution. -# -# - Set up verdaccio and publish all NPM tarballs found in the given directory to it. -# - Install the CLI from that Verdaccio fixture somewhere and put it -# on the PATH. -# - Prepare the various package managers to take their packages from dist/ as well. -# -# Parameter: DIST_ROOT, if different than the current directory. set -eu -scriptdir=$(cd $(dirname $0) && pwd) -source $scriptdir/run-against-dist.bash +# This is a backwards compatibility script. All logic has moved to '@aws-cdk-testing/cli-integ' +# and should be called from there directly. -# If DIST_ROOT is not given, guess at a sane location. -if [[ "${DIST_ROOT:-}" == "" && -f $scriptdir/../../../dist/build.json ]]; then - DIST_ROOT=$scriptdir/../../../dist -fi +export VERSION=$(node -pe "require('./build.json').version") -dist_root=$(cd ${DIST_ROOT:-.} && pwd) +# The package MUST be 'npm install'ed from the package repository (`npm install --production` +# will not work because that will resolve devDependencies even though it will not install them), +# but it may not live in a 'node_modules' directory because Jest 27 does not support that. Do contortions. +export INTEG_TOOLS=cli_integ +rm -rf $INTEG_TOOLS && mkdir $INTEG_TOOLS +npm install --prefix $INTEG_TOOLS --no-save ./js/aws-cdk-testing-cli-integ-*.tgz +mv $($INTEG_TOOLS/node_modules/.bin/test-root)/* $INTEG_TOOLS -if [[ ! -f $dist_root/build.json ]]; then - echo "$dist_root does not seem to be a built CDK distribution (change directory or use DIST_ROOT)" >&2 - exit 1 -fi +# Do a breakpoint for testing +codebuild-breakpoint -export CANDIDATE_VERSION=$(node -p "require('${dist_root}/build.json').version") - -# FRAMEWORK_VERSION is the version that will be 'npm install'ed by the tests -if [[ "${FRAMEWORK_VERSION:-}" = "" ]]; then - export FRAMEWORK_VERSION=${CANDIDATE_VERSION} -fi -export TEST_RUNNER=dist - -serve_npm_packages -install_cli - -prepare_java_packages -prepare_nuget_packages -prepare_python_packages - -# Install additional tool wrappers before running the target script -export PATH="$scriptdir/run-wrappers/dist:$PATH" -hash -r - -# Run target script -# NOTE: no 'exec' because we need to shutdown verdaccio only AFTER we've -# run the subscript. -"$@" +CONCURRENCY=5 exec ${INTEG_TOOLS}/bin/stage-distribution run . "$@" diff --git a/packages/aws-cdk/test/integ/run-against-dist.bash b/packages/aws-cdk/test/integ/run-against-dist.bash deleted file mode 100644 index 84162031f5068..0000000000000 --- a/packages/aws-cdk/test/integ/run-against-dist.bash +++ /dev/null @@ -1,147 +0,0 @@ -# Helper functions to go with 'run-against-dist' -# NPM Workspace. Will have CDK CLI and verdaccio installed into it. -npmws=/tmp/cdk-rundist -rm -rf $npmws -mkdir -p $npmws - -set -x - -# This script must create 1 or 2 traps, and the 'trap' command will replace -# the previous trap, so get some 'dynamic traps' mechanism in place -TRAPS=() - -function run_traps() { - for cmd in "${TRAPS[@]}"; do - echo "cleanup: $cmd" >&2 - eval "$cmd" - done -} - -trap run_traps EXIT - -function log() { - echo >&2 "| $@" -} - -function header() { - log - log "============================================================================================" - log $@ - log "============================================================================================" -} - -function serve_npm_packages() { - if [ -n "${SERVE_NPM_TARBALLS_PID:-}" ]; then - log >&2 "Verdaccio is already running" - return 1 - fi - - #------------------------------------------------------------------------------ - # Start a mock npm repository from the given tarballs - #------------------------------------------------------------------------------ - header "Starting local NPM Repository (Serving version ${CANDIDATE_VERSION})" - - tarballs_glob="$dist_root/js/*.tgz" - - if [[ -f package.json ]]; then - echo "Do not run this script in a directory with a package.json! It will most likely break!" >&2 - # Cowardly not running 'exit 1' because I'm not sure I won't mess up the build/canaries by doing so - fi - - # When using '--daemon', 'npm install' first so the files are permanent, or - # 'npx' will remove them too soon. - npm install serve-npm-tarballs - eval $(npx serve-npm-tarballs --glob "${tarballs_glob}" --daemon) - TRAPS+=("kill $SERVE_NPM_TARBALLS_PID") -} - -function install_cli() { - echo "Installing CLI aws-cdk@${CANDIDATE_VERSION}" - (cd ${npmws} && npm install --prefix $npmws aws-cdk@${CANDIDATE_VERSION}) - export PATH=$npmws/node_modules/.bin:$PATH -} - -function prepare_java_packages() { - log "Preparing Maven packages..." - - # copy the maven staging repo to the maven local repo and set as M2 home - # this ensures that the canary builds against the build artifacts, not maven central - if [ ! -d $dist_root/java ]; then - echo "Maven packages missing at $dist_root/java" >&2 - exit 1 - fi - - # Rename all maven-metadata.xml* files to maven-metadata-local.xml* - # This is necessary for Maven to find them correctly after we've rsync'ed - # them into place: - # https://github.com/sonatype/sonatype-aether/blob/master/aether-impl/src/main/java/org/sonatype/aether/impl/internal/SimpleLocalRepositoryManager.java#L114 - for f in $(find $dist_root/java -name maven-metadata.xml\*); do - mv "$f" "$(echo "$f" | sed s/metadata\.xml/metadata-local.xml/)" - done - - export MAVEN_CONFIG=${MAVEN_CONFIG:-$HOME/.m2} - rsync -a $dist_root/java/ ${MAVEN_CONFIG}/repository -} - -function prepare_nuget_packages() { - # For NuGet, we wrap the "dotnet" CLI command to use local packages. - log "Writing new NuGet configuration..." - - local NUGET_SOURCE=$dist_root/dotnet - - if [ ! -d "$NUGET_SOURCE" ]; then - echo "NuGet packages missing at $NUGET_SOURCE" >&2 - exit 1 - fi - - mkdir -p $HOME/.nuget/NuGet - if [ -f $HOME/.nuget/NuGet/NuGet.Config ]; then - echo "⚠️ Saving previous NuGet.Config to $HOME/.nuget/NuGet/NuGet.Config.bak" - mv $HOME/.nuget/NuGet/NuGet.Config $HOME/.nuget/NuGet/NuGet.Config.bak - fi - - TRAPS+=('clean_up_nuget_config') - - cat > $HOME/.nuget/NuGet/NuGet.Config < - - - - - - -EOF -} - -function clean_up_nuget_config() { - log "Restoring NuGet configuration" - if [ -f $HOME/.nuget/NuGet/NuGet.Config.bak ]; then - log "-> Restoring $HOME/.nuget/NuGet/NuGet.Config from $HOME/.nuget/NuGet/NuGet.Config.bak" - mv -f $HOME/.nuget/NuGet/NuGet.Config.bak $HOME/.nuget/NuGet/NuGet.Config - else - log "-> Removing $HOME/.nuget/NuGet/NuGet.Config" - rm -f $HOME/.nuget/NuGet/NuGet.Config - fi -} - -# pip_install REQUIREMENTS_FILE -function prepare_python_packages() { - log "Hijacking 'pip install' command..." - - # We can't use a $PATH hijack, because we'll be creating a venv - # later which will re-hijack ours with a 'pip' binary. Use a function instead, - # the real logic will reside in "pip_" - - export PYTHON_WHEELS=$dist_root/python - - if [ ! -d "$PYTHON_WHEELS" ]; then - echo "Python build artifacts missing at $PYTHON_WHEELS" >&2 - exit 1 - fi - - export -f pip -} - -function pip() { - pip_ "$@" -} diff --git a/packages/aws-cdk/test/integ/run-against-release b/packages/aws-cdk/test/integ/run-against-release index 5bfcbbfae7e4f..3602333135990 100755 --- a/packages/aws-cdk/test/integ/run-against-release +++ b/packages/aws-cdk/test/integ/run-against-release @@ -1,37 +1,18 @@ #!/bin/bash -# Run a given test against the publicly released packages -# -# - Install the latest CLI somewhere and put it on the PATH. -# - Run the script set -eu -scriptdir=$(cd $(dirname $0) && pwd) -CLI_INSTALLER="${CLI_INSTALLER:=npm}" +# This is a backwards compatibility script. All logic has moved to '@aws-cdk-testing/cli-integ' +# and should be called from there directly in the future. -if [ ${CLI_INSTALLER} = "npm" ]; then - install_command="install" -elif [ ${CLI_INSTALLER} = "yarn" ]; then - install_command="add" -else - echo "CLI_INSTALLER can only be set to either npm or yarn (got ${CLI_INSTALLER})" - exit 1 -fi +# The package MUST be 'npm install'ed from the package repository (`npm install --production` +# will not work because that will resolve devDependencies even though it will not install them), +# but it may not live in a 'node_modules' directory because Jest 27 does not support that. Do contortions. +export INTEG_TOOLS=cli_integ +rm -rf $INTEG_TOOLS && mkdir $INTEG_TOOLS +npm install --prefix $INTEG_TOOLS --no-save @aws-cdk-testing/cli-integ@${RELEASE_TAG:-latest} +mv $($INTEG_TOOLS/node_modules/.bin/test-root)/* $INTEG_TOOLS -# NPM Workspace. Will have CDK CLI installed into it. -npmws=/tmp/cdk-runrelease -rm -rf $npmws -mkdir -p $npmws +# Find the latest CLI version in this tag +npm view aws-cdk@${RELEASE_TAG:-latest} --json > release.json +export VERSION=$(node -pe "require('./release.json').version") -# Install the CLI and put it on the PATH -(cd $npmws && ${CLI_INSTALLER} ${install_command} aws-cdk@${RELEASE_TAG:-latest}) - -# FRAMEWORK_VERSION is the version that will be 'npm install'ed by the tests -if [[ "${FRAMEWORK_VERSION:-}" = "" ]]; then - cli_version=$(cd $npmws && node -p "require('aws-cdk/package.json').version") - export FRAMEWORK_VERSION=${cli_version} -fi - -export PATH=$npmws/node_modules/.bin:$PATH -export TEST_RUNNER=release - -# Run the inner script exec "$@" diff --git a/packages/aws-cdk/test/integ/run-against-repo b/packages/aws-cdk/test/integ/run-against-repo deleted file mode 100755 index 420850f2cd951..0000000000000 --- a/packages/aws-cdk/test/integ/run-against-repo +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/bash -# Script to run a given test against the monorepo. -# -# Set up paths so that `cdk` binary is on the path, and make it -# so that `npm install` symlinks from the monorepo package directories. -set -eu - -cli_dir=$(cd $(dirname $0)/../.. && pwd) -repo_root=$(cd $cli_dir/../.. && pwd) - -if [[ ! -f $repo_root/package.json ]]; then - echo "$repo_root does not seem to be the root of the aws-cdk repository." >&2 - exit 1 -fi - -export REPO_ROOT="$repo_root" -export ORIGINAL_NPM="$(type -p npm)" -export TEST_RUNNER=repo - -export PATH="$cli_dir/bin:$cli_dir/test/integ/run-wrappers/repo:$PATH" -hash -r -exec "$@" diff --git a/packages/aws-cdk/test/integ/run-wrappers/dist/pip_ b/packages/aws-cdk/test/integ/run-wrappers/dist/pip_ deleted file mode 100755 index ce580ea30a5f7..0000000000000 --- a/packages/aws-cdk/test/integ/run-wrappers/dist/pip_ +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/bash -set -eu -if [[ "${1:-}" == "install" ]]; then - # We will receive `pip install -r requirements.txt` and need to - # install the packages from the local dist. We previously just - # installed everything under $PYTHON_WHEELS ($PYTHON_WHEELS/*.whl). - # However, there is a bug that arises on v2 when we install everything, - # including both `aws-cdk-lib` and `cx-api`, because the latter is also - # packaged in the former and causes conflicts. This can lead to errors like: - # "Unknown type: aws-cdk-lib.cx_api.CloudAssembly" - # Since we only need aws-cdk-lib anyway (for now), just install it alone. - exec pip install ${PYTHON_WHEELS}/aws_cdk_lib*.whl -fi - -exec pip "$@" diff --git a/packages/aws-cdk/test/integ/run-wrappers/repo/dotnet b/packages/aws-cdk/test/integ/run-wrappers/repo/dotnet deleted file mode 100755 index 7ab610a0e7afd..0000000000000 --- a/packages/aws-cdk/test/integ/run-wrappers/repo/dotnet +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/bash -echo "$0: cannot build this kind of project against the repo. Only pure NPM projects are supported. Use 'run-against-dist' instead." >&2 -exit 1 diff --git a/packages/aws-cdk/test/integ/run-wrappers/repo/mvn b/packages/aws-cdk/test/integ/run-wrappers/repo/mvn deleted file mode 100755 index 7ab610a0e7afd..0000000000000 --- a/packages/aws-cdk/test/integ/run-wrappers/repo/mvn +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/bash -echo "$0: cannot build this kind of project against the repo. Only pure NPM projects are supported. Use 'run-against-dist' instead." >&2 -exit 1 diff --git a/packages/aws-cdk/test/integ/run-wrappers/repo/pip_ b/packages/aws-cdk/test/integ/run-wrappers/repo/pip_ deleted file mode 100755 index 9553f9cefe2d9..0000000000000 --- a/packages/aws-cdk/test/integ/run-wrappers/repo/pip_ +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/bash -echo "$0: cannot build this kind of project against the repo. Only pure NPM projects are supported. Use 'run-against-dist' instead." >&2 -exit 1 - diff --git a/packages/aws-cdk/test/integ/test-cli-regression-against-current-code.sh b/packages/aws-cdk/test/integ/test-cli-regression-against-current-code.sh index ff50aa5f69a2b..c735580c9fd58 100755 --- a/packages/aws-cdk/test/integ/test-cli-regression-against-current-code.sh +++ b/packages/aws-cdk/test/integ/test-cli-regression-against-current-code.sh @@ -1,11 +1,12 @@ #!/bin/bash -# -# Run our integration tests in regression mode against the -# candidate version of the framework, which is the one we just packed. -# -set -euo pipefail -integdir=$(cd $(dirname $0) && pwd) +set -eu +set -x +# This is a backwards compatibilty script. All logic has moved to '@aws-cdk-testing/cli-integ' +# and should be called from there directly. -source ${integdir}/test-cli-regression.bash +# Contract: '@aws-cdk-testing/cli-integ' package is installed in ${INTEG_TOOLS} +previous=$(${INTEG_TOOLS}/bin/query-github last-release --token $GITHUB_TOKEN --prior-to $VERSION) +echo "Previous version is: $previous" -run_regression_against_framework_version CANDIDATE_VERSION +# Old tests, new CLI, new framework +exec $INTEG_TOOLS/bin/download-and-run-old-tests "$previous" --use-cli-release=$VERSION cli-integ-tests diff --git a/packages/aws-cdk/test/integ/test-cli-regression-against-latest-release.sh b/packages/aws-cdk/test/integ/test-cli-regression-against-latest-release.sh index 8b670eb7b793d..8c828fb2138ce 100755 --- a/packages/aws-cdk/test/integ/test-cli-regression-against-latest-release.sh +++ b/packages/aws-cdk/test/integ/test-cli-regression-against-latest-release.sh @@ -1,11 +1,11 @@ #!/bin/bash -# -# Run our integration tests in regression mode against the -# previous version of the framework, relative to the version being packed now. -# -set -euo pipefail -integdir=$(cd $(dirname $0) && pwd) +set -eu +# This is a backwards compatibility script. All logic has moved to '@aws-cdk-testing/cli-integ' +# and should be called from there directly. -source ${integdir}/test-cli-regression.bash +# Contract: '@aws-cdk-testing/cli-integ' package is installed in ${INTEG_TOOLS} +previous=$(${INTEG_TOOLS}/bin/query-github last-release --token $GITHUB_TOKEN --prior-to $VERSION) +echo "Previous version is: $previous" -run_regression_against_framework_version PREVIOUS_VERSION +# Old tests, new CLI, old framework +exec $INTEG_TOOLS/bin/download-and-run-old-tests "$previous" --use-cli-release=$VERSION --framework-version=$previous cli-integ-tests diff --git a/packages/aws-cdk/test/integ/typescript-versions.ts b/packages/aws-cdk/test/integ/typescript-versions.ts deleted file mode 100644 index cf86653b99793..0000000000000 --- a/packages/aws-cdk/test/integ/typescript-versions.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { spawnSync } from 'child_process'; - -const minSupportedVersion = process.argv.slice(2, 3); - -const { stdout } = spawnSync('npm', ['--silent', 'view', `typescript@>=${minSupportedVersion}`, 'version', '--json']); - -const versions: string[] = JSON.parse(stdout); -const minorVersions = Array.from(new Set(versions.map(v => v.split('.').slice(0, 2).join('.')))); - -process.stdout.write(minorVersions.join(' ')); diff --git a/packages/aws-cdk/test/integ/uberpackage/jest.config.js b/packages/aws-cdk/test/integ/uberpackage/jest.config.js deleted file mode 100644 index 1e3fe3d13f96b..0000000000000 --- a/packages/aws-cdk/test/integ/uberpackage/jest.config.js +++ /dev/null @@ -1,15 +0,0 @@ -module.exports = { - moduleFileExtensions: [ - "js", - ], - testMatch: [ - "**/*.integtest.js", - ], - testEnvironment: "node", - bail: 1, - verbose: true, - reporters: [ - "default", - [ "jest-junit", { suiteName: "jest tests", outputDirectory: "coverage" } ] - ] -}; diff --git a/packages/aws-cdk/test/integ/uberpackage/test.sh b/packages/aws-cdk/test/integ/uberpackage/test.sh index 41761b349580e..005ad2ffe1544 100755 --- a/packages/aws-cdk/test/integ/uberpackage/test.sh +++ b/packages/aws-cdk/test/integ/uberpackage/test.sh @@ -1,14 +1,6 @@ #!/bin/bash +set -eu +# This is a backwards compatibility script. All logic has moved to '@aws-cdk-testing/cli-integ' +# and should be called from there directly. -set -euo pipefail - -scriptdir=$(cd $(dirname $0) && pwd) - -echo '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~' -echo 'UberCDK Integration Tests' -echo '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~' - -cd $scriptdir - -source ../common/jest-test.bash -invokeJest "$@" +exec ${INTEG_TOOLS}/bin/run-suite --use-cli-release=$VERSION uberpackage diff --git a/packages/aws-cdk/test/rwlock.test.ts b/packages/aws-cdk/test/rwlock.test.ts new file mode 100644 index 0000000000000..d241eaaf96844 --- /dev/null +++ b/packages/aws-cdk/test/rwlock.test.ts @@ -0,0 +1,52 @@ +import * as os from 'os'; +import * as path from 'path'; +import { RWLock } from '../lib/api/util/rwlock'; + +function testDir() { + return path.join(os.tmpdir(), 'rwlock-tests'); +} + +test('writer lock excludes other locks', async () => { + // GIVEN + const lock = new RWLock(testDir()); + const w = await lock.acquireWrite(); + + // WHEN + try { + await expect(lock.acquireWrite()).rejects.toThrow(/currently synthing/); + await expect(lock.acquireRead()).rejects.toThrow(/currently synthing/); + } finally { + await w.release(); + } +}); + +test('reader lock allows other readers but not writers', async () => { + // GIVEN + const lock = new RWLock(testDir()); + const r = await lock.acquireRead(); + + // WHEN + try { + await expect(lock.acquireWrite()).rejects.toThrow(/currently reading/); + + const r2 = await lock.acquireRead(); + await r2.release(); + } finally { + await r.release(); + } +}); + +test('can convert writer to reader lock', async () => { + // GIVEN + const lock = new RWLock(testDir()); + const w = await lock.acquireWrite(); + + // WHEN + const r = await w.convertToReaderLock(); + try { + const r2 = await lock.acquireRead(); + await r2.release(); + } finally { + await r.release(); + } +}); \ No newline at end of file diff --git a/packages/aws-cdk/test/util.ts b/packages/aws-cdk/test/util.ts index 751c1c1ad6bba..97d7e519e9be2 100644 --- a/packages/aws-cdk/test/util.ts +++ b/packages/aws-cdk/test/util.ts @@ -239,3 +239,7 @@ export function withMocked(obj: A, key: function isPromise(object: any): object is Promise { return Promise.resolve(object) === object; } + +export async function sleep(ms: number) { + return new Promise(ok => setTimeout(ok, ms)); +} diff --git a/packages/aws-cdk/test/util/stack-monitor.test.ts b/packages/aws-cdk/test/util/stack-monitor.test.ts index 7e2644b481b9f..12bc5ac80007e 100644 --- a/packages/aws-cdk/test/util/stack-monitor.test.ts +++ b/packages/aws-cdk/test/util/stack-monitor.test.ts @@ -1,5 +1,5 @@ import { StackActivityMonitor, IActivityPrinter, StackActivity } from '../../lib/api/util/cloudformation/stack-activity-monitor'; -import { sleep } from '../integ/helpers/aws'; +import { sleep } from '../util'; import { MockSdk } from './mock-sdk'; let sdk: MockSdk; diff --git a/tools/@aws-cdk/cdk-release/lib/lifecycles/bump.ts b/tools/@aws-cdk/cdk-release/lib/lifecycles/bump.ts index 0a6417cb080d6..055c6bdee3cb9 100644 --- a/tools/@aws-cdk/cdk-release/lib/lifecycles/bump.ts +++ b/tools/@aws-cdk/cdk-release/lib/lifecycles/bump.ts @@ -28,7 +28,7 @@ export async function bump(args: BumpOptions, currentVersion: Versions): Promise const newVersion: Versions = { stableVersion: newStableVersion, - alphaVersion: bumpAlphaReleaseVersion(currentVersion, releaseType), + alphaVersion: bumpAlphaReleaseVersion(currentVersion, newStableVersion, releaseType), }; notify(args, @@ -108,19 +108,43 @@ function getTypePriority(type: string): number { /** * https://github.com/aws/aws-cdk/issues/15581 * We version any alpha modules in one of two ways, depending on the main/stable release. - * If the main release is itself a prerelease (e.g., 2.0.0-rc.17), - * we will increment the current alpha release. + * + * If the main release is itself a prerelease (e.g., 2.0.0-rc.17): + * - if the current alpha version has the same major.minor.patch version as the current stable, + * we probably have a long-running RC candidate that we are actually releasing. Increment the + * current alpha release. + * - if not, then we are probably coming up with a testing RC version for the pipeline. We must + * come up with an alpha version that can never be released publicly, because our version numbers + * must never be the same as any publicly released package. Use '2.0.0-alpha.999' for those. + * * If the main release is not a prerelease, we use the main release version, but with an alpha tag. + * + * This logic is mirrored in the integ tests. */ -function bumpAlphaReleaseVersion(currentVersion: Versions, releaseType: semver.ReleaseType): string | undefined { - if (!currentVersion.alphaVersion) { return undefined; } +function bumpAlphaReleaseVersion(previousVersions: Versions, currentStable: string, releaseType: semver.ReleaseType): string | undefined { + if (!previousVersions.alphaVersion) { return undefined; } + + let newAlphaVersion; + if (releaseType.startsWith('pre')) { + // Prerelease, either long-running or just a unique one to test + const stableV = semver.parse(currentStable); + const alphaV = semver.parse(previousVersions.alphaVersion); + if (!stableV || !alphaV) { + throw new Error(`Could not parse either ${currentStable} or ${previousVersions.alphaVersion} as a version`); + } - const newAlphaVersion = releaseType.startsWith('pre') - ? semver.inc(currentVersion.alphaVersion, releaseType, 'alpha') - : semver.inc(currentVersion.stableVersion, 'pre' + releaseType as semver.ReleaseType, 'alpha'); + if (stableV?.compareMain(alphaV) === 0) { + newAlphaVersion = semver.inc(previousVersions.alphaVersion, releaseType, 'alpha'); + } else { + newAlphaVersion = semver.inc(previousVersions.stableVersion, releaseType as semver.ReleaseType, 'alpha')?.replace(/0$/, '999'); + } + } else { + // Stable release, add `-alpha.0` to the end of the stable release version + newAlphaVersion = semver.inc(previousVersions.stableVersion, 'pre' + releaseType as semver.ReleaseType, 'alpha'); + } if (!newAlphaVersion) { - throw new Error('Could not increment alpha version: ' + currentVersion.alphaVersion); + throw new Error('Could not increment alpha version: ' + previousVersions.alphaVersion); } return newAlphaVersion; } diff --git a/tools/@aws-cdk/cdk-release/test/bump.test.ts b/tools/@aws-cdk/cdk-release/test/bump.test.ts index df0d08eaae828..234b8d0c6fdfd 100644 --- a/tools/@aws-cdk/cdk-release/test/bump.test.ts +++ b/tools/@aws-cdk/cdk-release/test/bump.test.ts @@ -45,7 +45,7 @@ describe('stable versions', () => { describe('alpha versions', () => { - test('for prerelease, bumps existing alpha counter as a prerelease', async () => { + test('long-running prerelease: bumps existing alpha counter as a prerelease', async () => { const currentVersion = { stableVersion: '1.2.0-rc.4', alphaVersion: '1.2.0-alpha.0' }; const bumpedVersion = await bump({ releaseAs: 'minor', versionFile: 'version.json', prerelease: 'rc' }, currentVersion); @@ -55,8 +55,18 @@ describe('alpha versions', () => { }); }); - test('for normal releases, bumps alpha as a prerelease of stable release', async () => { - const currentVersion = { stableVersion: '1.2.0', alphaVersion: '1.1.0-alpha.0' }; + test('one-off prerelease: alpha is a prerelease of stable release with crazy alpha tag', async () => { + const currentVersion = { stableVersion: '1.2.0', alphaVersion: '1.2.0-alpha.0' }; + const bumpedVersion = await bump({ releaseAs: 'minor', versionFile: 'version.json', prerelease: 'rc' }, currentVersion); + + expect(bumpedVersion).toEqual({ + stableVersion: '1.3.0-rc.0', + alphaVersion: '1.3.0-alpha.999', + }); + }); + + test('normal release: alpha is a prerelease of stable release with realistic alpha tag', async () => { + const currentVersion = { stableVersion: '1.2.0', alphaVersion: '1.2.0-alpha.0' }; const bumpedVersion = await bump({ releaseAs: 'minor', versionFile: 'version.json' }, currentVersion); expect(bumpedVersion).toEqual({ diff --git a/tools/@aws-cdk/pkglint/lib/rules.ts b/tools/@aws-cdk/pkglint/lib/rules.ts index 9f257954fcabc..0351e1e4a7a47 100644 --- a/tools/@aws-cdk/pkglint/lib/rules.ts +++ b/tools/@aws-cdk/pkglint/lib/rules.ts @@ -1676,6 +1676,7 @@ export class UbergenPackageVisibility extends ValidationRule { 'cdk', 'cdk-assets', '@aws-cdk/integ-runner', + '@aws-cdk-testing/cli-integ', ]; public validate(pkg: PackageJson): void { diff --git a/tools/@aws-cdk/prlint/lint.ts b/tools/@aws-cdk/prlint/lint.ts index aaf1c8f0389c1..53e1d877f8fb9 100644 --- a/tools/@aws-cdk/prlint/lint.ts +++ b/tools/@aws-cdk/prlint/lint.ts @@ -306,6 +306,9 @@ export class PullRequestLinter { validationCollector.validateRuleSet({ testRuleSet: [ { test: validateTitlePrefix } ] }); + validationCollector.validateRuleSet({ + testRuleSet: [ { test: validateTitleScope } ] + }) validationCollector.validateRuleSet({ exemption: shouldExemptBreakingChange, @@ -446,6 +449,29 @@ function hasLabel(pr: GitHubPr, labelName: string): boolean { return result; }; +/** + * Check that the PR title uses the typical convention for package names. + * + * For example, "fix(s3)" is preferred over "fix(aws-s3)". + */ +function validateTitleScope(pr: GitHubPr): TestResult { + const result = new TestResult(); + // Specific commit types are handled by `validateTitlePrefix`. This just checks whether + // the scope includes an `aws-` prefix or not. + // Group 1: Scope with parens - "(aws-)" + // Group 2: Scope name - "aws-" + // Group 3: Preferred scope name - "" + const titleRe = /^\w+(\((aws-([\w_-]+))\))?: /; + const m = titleRe.exec(pr.title); + if (m) { + result.assessFailure( + !!(m[2] && m[3]), + `The title of the pull request should omit 'aws-' from the name of modified packages. Use '${m[3]}' instead of '${m[2]}'.`, + ); + } + return result; +} + function assertStability(pr: GitHubPr, _files: GitHubFile[]): TestResult { const title = pr.title; const body = pr.body; diff --git a/tools/@aws-cdk/prlint/test/lint.test.ts b/tools/@aws-cdk/prlint/test/lint.test.ts index ca417917af878..d498f857d54a0 100644 --- a/tools/@aws-cdk/prlint/test/lint.test.ts +++ b/tools/@aws-cdk/prlint/test/lint.test.ts @@ -58,6 +58,63 @@ describe('breaking changes format', () => { }); }); +describe('commit message format', () => { + test('valid scope', async () => { + const issue = { + number: 1, + title: 'chore(s3): some title', + body: '', + labels: [], + }; + const prLinter = configureMock(issue, undefined); + expect(await prLinter.validate()).resolves; + }); + + test('invalid scope with aws- prefix', async () => { + const issue = { + number: 1, + title: 'fix(aws-s3): some title', + body: '', + labels: [{ name: 'pr-linter/exempt-test' }, { name: 'pr-linter/exempt-integ-test' }], + }; + const prLinter = configureMock(issue, undefined); + await expect(prLinter.validate()).rejects.toThrow(/The title of the pull request should omit 'aws-' from the name of modified packages. Use 's3' instead of 'aws-s3'./); + }); + + test('valid scope with aws- in summary and body', async () => { + const issue = { + number: 1, + title: 'docs(s3): something aws-s3', + body: 'something aws-s3', + labels: [], + }; + const prLinter = configureMock(issue, undefined); + expect(await prLinter.validate()).resolves; + }); + + test('valid with missing scope', async () => { + const issue = { + number: 1, + title: 'docs: something aws-s3', + body: '', + labels: [], + }; + const prLinter = configureMock(issue, undefined); + expect(await prLinter.validate()).resolves; + }); + + test.each(['core', 'prlint', 'awslint'])('valid scope for packages that dont use aws- prefix', async (scope) => { + const issue = { + number: 1, + title: `chore(${scope}): some title`, + body: '', + labels: [] + }; + const prLinter = configureMock(issue, undefined); + expect(await prLinter.validate()).resolves; + }) +}); + describe('ban breaking changes in stable modules', () => { test('breaking change in stable module', async () => { const issue = { diff --git a/yarn.lock b/yarn.lock index ac9b8471893a3..e0c13a7618320 100644 --- a/yarn.lock +++ b/yarn.lock @@ -348,6 +348,11 @@ resolved "https://registry.npmjs.org/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" integrity sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw== +"@colors/colors@1.5.0": + version "1.5.0" + resolved "https://registry.npmjs.org/@colors/colors/-/colors-1.5.0.tgz#bb504579c1cae923e6576a4f5da43d25f97bdbd9" + integrity sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ== + "@cspotcode/source-map-support@^0.8.0": version "0.8.1" resolved "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz#00629c35a688e05a88b1cda684fb9d5e73f000a1" @@ -538,6 +543,11 @@ resolved "https://registry.npmjs.org/@iarna/toml/-/toml-2.2.5.tgz#b32366c89b43c6f8cefbdefac778b9c828e3ba8c" integrity sha512-trnsAYxU3xnS1gPHPyU961coFyLkh4gAD/0zQ5mymY4yOZ+CYvsPqUbOFSw0aDM4y0tV7tiFxL/1XfXPNC6IPg== +"@isaacs/string-locale-compare@^1.1.0": + version "1.1.0" + resolved "https://registry.npmjs.org/@isaacs/string-locale-compare/-/string-locale-compare-1.1.0.tgz#291c227e93fd407a96ecd59879a35809120e432b" + integrity sha512-SQ7Kzhh9+D+ZW9MA0zkYv3VXhIDNx+LzM6EJ+/65I3QY+enU6Itte7E5XX7EWrqLW2FN4n06GWzBnPoC3th2aQ== + "@istanbuljs/load-nyc-config@^1.0.0": version "1.1.0" resolved "https://registry.npmjs.org/@istanbuljs/load-nyc-config/-/load-nyc-config-1.1.0.tgz#fd3db1d59ecf7cf121e80650bb86712f9b55eced" @@ -1489,11 +1499,80 @@ "@nodelib/fs.scandir" "2.1.5" fastq "^1.6.0" +"@npmcli/arborist@^5.0.4", "@npmcli/arborist@^5.6.3": + version "5.6.3" + resolved "https://registry.npmjs.org/@npmcli/arborist/-/arborist-5.6.3.tgz#40810080272e097b4a7a4f56108f4a31638a9874" + integrity sha512-/7hbqEM6YuRjwTcQXkK1+xKslEblY5kFQe0tZ7jKyMlIR6x4iOmhLErIkBBGtTKvYxRKdpcxnFXjCobg3UqmsA== + dependencies: + "@isaacs/string-locale-compare" "^1.1.0" + "@npmcli/installed-package-contents" "^1.0.7" + "@npmcli/map-workspaces" "^2.0.3" + "@npmcli/metavuln-calculator" "^3.0.1" + "@npmcli/move-file" "^2.0.0" + "@npmcli/name-from-folder" "^1.0.1" + "@npmcli/node-gyp" "^2.0.0" + "@npmcli/package-json" "^2.0.0" + "@npmcli/query" "^1.2.0" + "@npmcli/run-script" "^4.1.3" + bin-links "^3.0.3" + cacache "^16.1.3" + common-ancestor-path "^1.0.1" + hosted-git-info "^5.2.1" + json-parse-even-better-errors "^2.3.1" + json-stringify-nice "^1.1.4" + minimatch "^5.1.0" + mkdirp "^1.0.4" + mkdirp-infer-owner "^2.0.0" + nopt "^6.0.0" + npm-install-checks "^5.0.0" + npm-package-arg "^9.0.0" + npm-pick-manifest "^7.0.2" + npm-registry-fetch "^13.0.0" + npmlog "^6.0.2" + pacote "^13.6.1" + parse-conflict-json "^2.0.1" + proc-log "^2.0.0" + promise-all-reject-late "^1.0.0" + promise-call-limit "^1.0.1" + read-package-json-fast "^2.0.2" + readdir-scoped-modules "^1.1.0" + rimraf "^3.0.2" + semver "^7.3.7" + ssri "^9.0.0" + treeverse "^2.0.0" + walk-up-path "^1.0.0" + "@npmcli/ci-detect@^1.0.0": version "1.4.0" resolved "https://registry.npmjs.org/@npmcli/ci-detect/-/ci-detect-1.4.0.tgz#18478bbaa900c37bfbd8a2006a6262c62e8b0fe1" integrity sha512-3BGrt6FLjqM6br5AhWRKTr3u5GIVkjRYeAFrMp3HjnfICrg4xOrVRwFavKT6tsp++bq5dluL5t8ME/Nha/6c1Q== +"@npmcli/ci-detect@^2.0.0": + version "2.0.0" + resolved "https://registry.npmjs.org/@npmcli/ci-detect/-/ci-detect-2.0.0.tgz#e63c91bcd4185ac1e85720a34fc48e164ece5b89" + integrity sha512-8yQtQ9ArHh/TzdUDKQwEvwCgpDuhSWTDAbiKMl3854PcT+Dk4UmWaiawuFTLy9n5twzXOBXVflWe+90/ffXQrA== + +"@npmcli/config@^4.1.0": + version "4.2.2" + resolved "https://registry.npmjs.org/@npmcli/config/-/config-4.2.2.tgz#2e3334dda84f48d059309c53d152e66b05ca24b7" + integrity sha512-5GNcLd+0c4bYBnFop53+26CO5GQP0R9YcxlernohpHDWdIgzUg9I0+GEMk3sNHnLntATVU39d283A4OO+W402w== + dependencies: + "@npmcli/map-workspaces" "^2.0.2" + ini "^3.0.0" + mkdirp-infer-owner "^2.0.0" + nopt "^6.0.0" + proc-log "^2.0.0" + read-package-json-fast "^2.0.3" + semver "^7.3.5" + walk-up-path "^1.0.0" + +"@npmcli/disparity-colors@^2.0.0": + version "2.0.0" + resolved "https://registry.npmjs.org/@npmcli/disparity-colors/-/disparity-colors-2.0.0.tgz#cb518166ee21573b96241a3613fef70acb2a60ba" + integrity sha512-FFXGrIjhvd2qSZ8iS0yDvbI7nbjdyT2VNO7wotosjYZM2p2r8PN3B7Om3M5NO9KqW/OVzfzLB3L0V5Vo5QXC7A== + dependencies: + ansi-styles "^4.3.0" + "@npmcli/fs@^1.0.0": version "1.1.1" resolved "https://registry.npmjs.org/@npmcli/fs/-/fs-1.1.1.tgz#72f719fe935e687c56a4faecf3c03d06ba593257" @@ -1502,7 +1581,7 @@ "@gar/promisify" "^1.0.1" semver "^7.3.5" -"@npmcli/fs@^2.1.0": +"@npmcli/fs@^2.1.0", "@npmcli/fs@^2.1.1": version "2.1.2" resolved "https://registry.npmjs.org/@npmcli/fs/-/fs-2.1.2.tgz#a9e2541a4a2fec2e69c29b35e6060973da79b865" integrity sha512-yOJKRvohFOaLqipNtwYB9WugyZKhC/DZC4VYPmpaCzDBrA8YpK3qHZ8/HGscMnE4GqbkLNuVcCnxkeQEdGt6LQ== @@ -1547,6 +1626,26 @@ npm-bundled "^1.1.1" npm-normalize-package-bin "^1.0.1" +"@npmcli/map-workspaces@^2.0.2", "@npmcli/map-workspaces@^2.0.3": + version "2.0.4" + resolved "https://registry.npmjs.org/@npmcli/map-workspaces/-/map-workspaces-2.0.4.tgz#9e5e8ab655215a262aefabf139782b894e0504fc" + integrity sha512-bMo0aAfwhVwqoVM5UzX1DJnlvVvzDCHae821jv48L1EsrYwfOZChlqWYXEtto/+BkBXetPbEWgau++/brh4oVg== + dependencies: + "@npmcli/name-from-folder" "^1.0.1" + glob "^8.0.1" + minimatch "^5.0.1" + read-package-json-fast "^2.0.3" + +"@npmcli/metavuln-calculator@^3.0.1": + version "3.1.1" + resolved "https://registry.npmjs.org/@npmcli/metavuln-calculator/-/metavuln-calculator-3.1.1.tgz#9359bd72b400f8353f6a28a25c8457b562602622" + integrity sha512-n69ygIaqAedecLeVH3KnO39M6ZHiJ2dEv5A7DGvcqCB8q17BGUgW8QaanIkbWUo2aYGZqJaOORTLAlIvKjNDKA== + dependencies: + cacache "^16.0.0" + json-parse-even-better-errors "^2.3.1" + pacote "^13.0.3" + semver "^7.3.5" + "@npmcli/move-file@^1.0.1": version "1.1.2" resolved "https://registry.npmjs.org/@npmcli/move-file/-/move-file-1.1.2.tgz#1a82c3e372f7cae9253eb66d72543d6b8685c674" @@ -1563,6 +1662,11 @@ mkdirp "^1.0.4" rimraf "^3.0.2" +"@npmcli/name-from-folder@^1.0.1": + version "1.0.1" + resolved "https://registry.npmjs.org/@npmcli/name-from-folder/-/name-from-folder-1.0.1.tgz#77ecd0a4fcb772ba6fe927e2e2e155fbec2e6b1a" + integrity sha512-qq3oEfcLFwNfEYOQ8HLimRGKlD8WSeGEdtUa7hmzpR8Sa7haL1KVQrvgO6wqMjhWFFVjgtrh1gIxDz+P8sjUaA== + "@npmcli/node-gyp@^1.0.2": version "1.0.3" resolved "https://registry.npmjs.org/@npmcli/node-gyp/-/node-gyp-1.0.3.tgz#a912e637418ffc5f2db375e93b85837691a43a33" @@ -1573,6 +1677,13 @@ resolved "https://registry.npmjs.org/@npmcli/node-gyp/-/node-gyp-2.0.0.tgz#8c20e53e34e9078d18815c1d2dda6f2420d75e35" integrity sha512-doNI35wIe3bBaEgrlPfdJPaCpUR89pJWep4Hq3aRdh6gKazIVWfs0jHttvSSoq47ZXgC7h73kDsUl8AoIQUB+A== +"@npmcli/package-json@^2.0.0": + version "2.0.0" + resolved "https://registry.npmjs.org/@npmcli/package-json/-/package-json-2.0.0.tgz#3bbcf4677e21055adbe673d9f08c9f9cde942e4a" + integrity sha512-42jnZ6yl16GzjWSH7vtrmWyJDGVa/LXPdpN2rcUWolFjc9ON2N3uz0qdBbQACfmhuJZ2lbKYtmK5qx68ZPLHMA== + dependencies: + json-parse-even-better-errors "^2.3.1" + "@npmcli/promise-spawn@^1.2.0", "@npmcli/promise-spawn@^1.3.2": version "1.3.2" resolved "https://registry.npmjs.org/@npmcli/promise-spawn/-/promise-spawn-1.3.2.tgz#42d4e56a8e9274fba180dabc0aea6e38f29274f5" @@ -1587,6 +1698,15 @@ dependencies: infer-owner "^1.0.4" +"@npmcli/query@^1.2.0": + version "1.2.0" + resolved "https://registry.npmjs.org/@npmcli/query/-/query-1.2.0.tgz#46468d583cf013aa92102970700f9555314aabe4" + integrity sha512-uWglsUM3PjBLgTSmZ3/vygeGdvWEIZ3wTUnzGFbprC/RtvQSaT+GAXu1DXmSFj2bD3oOZdcRm1xdzsV2z1YWdw== + dependencies: + npm-package-arg "^9.1.0" + postcss-selector-parser "^6.0.10" + semver "^7.3.7" + "@npmcli/run-script@^1.8.2": version "1.8.6" resolved "https://registry.npmjs.org/@npmcli/run-script/-/run-script-1.8.6.tgz#18314802a6660b0d4baa4c3afe7f1ad39d8c28b7" @@ -1597,7 +1717,17 @@ node-gyp "^7.1.0" read-package-json-fast "^2.0.1" -"@npmcli/run-script@^4.1.0": +"@npmcli/run-script@^3.0.1": + version "3.0.3" + resolved "https://registry.npmjs.org/@npmcli/run-script/-/run-script-3.0.3.tgz#66afa6e0c4c3484056195f295fa6c1d1a45ddf58" + integrity sha512-ZXL6qgC5NjwfZJ2nET+ZSLEz/PJgJ/5CU90C2S66dZY4Jw73DasS4ZCXuy/KHWYP0imjJ4VtA+Gebb5BxxKp9Q== + dependencies: + "@npmcli/node-gyp" "^2.0.0" + "@npmcli/promise-spawn" "^3.0.0" + node-gyp "^8.4.1" + read-package-json-fast "^2.0.3" + +"@npmcli/run-script@^4.1.0", "@npmcli/run-script@^4.1.3", "@npmcli/run-script@^4.2.0": version "4.2.1" resolved "https://registry.npmjs.org/@npmcli/run-script/-/run-script-4.2.1.tgz#c07c5c71bc1c70a5f2a06b0d4da976641609b946" integrity sha512-7dqywvVudPSrRCW5nTHpHgeWnbBtz8cFkOuKrecm6ih+oO9ciydhWt6OF7HlqupRRmB8Q/gECVdB9LMfToJbRg== @@ -1920,7 +2050,7 @@ dependencies: "@types/node" "*" -"@types/fs-extra@^9.0.13": +"@types/fs-extra@^9.0.0", "@types/fs-extra@^9.0.13": version "9.0.13" resolved "https://registry.npmjs.org/@types/fs-extra/-/fs-extra-9.0.13.tgz#7594fbae04fe7f1918ce8b3d213f74ff44ac1f45" integrity sha512-nEnwB++1u5lVDM2UI4c1+5R+FYaKfaAzS4OococimjVm3nQw3TuzH5UNsocrcTBbhnerblyHj4A49qXbIiZdpA== @@ -2054,6 +2184,11 @@ resolved "https://registry.npmjs.org/@types/node/-/node-18.11.18.tgz#8dfb97f0da23c2293e554c5a50d61ef134d7697f" integrity sha512-DHQpWGjyQKSHj3ebjFI/wRKcqQcdR+MoFBygntYOZytCqNfkd2ZC4ARDJ2DQqhjH5p85Nnd3jhUJIXrszFX/JA== +"@types/node@^14.18.31": + version "14.18.35" + resolved "https://registry.npmjs.org/@types/node/-/node-14.18.35.tgz#879c4659cb7b3fe515844f029c75079c941bb65c" + integrity sha512-2ATO8pfhG1kDvw4Lc4C0GXIMSQFFJBCo/R1fSgTwmUlq5oy95LXyjDQinsRVgQY6gp6ghh3H91wk9ES5/5C+Tw== + "@types/node@^14.18.36": version "14.18.36" resolved "https://registry.npmjs.org/@types/node/-/node-14.18.36.tgz#c414052cb9d43fab67d679d5f3c641be911f5835" @@ -2069,6 +2204,13 @@ resolved "https://registry.npmjs.org/@types/normalize-package-data/-/normalize-package-data-2.4.1.tgz#d3357479a0fdfdd5907fe67e17e0a85c906e1301" integrity sha512-Gj7cI7z+98M282Tqmp2K5EIsoouUEzbBJhQQzDE3jSIRk6r9gsz0oUokqIUR4u1R3dMHo0pDHM7sNOHyhulypw== +"@types/npm@^7.19.0": + version "7.19.0" + resolved "https://registry.npmjs.org/@types/npm/-/npm-7.19.0.tgz#a62382cea8ca8ef8452553e3d5daa68a331cda70" + integrity sha512-K/w+k8SnDjdQoK2fkUl9fHLAiVVmdFgdZ2/iGFuaaQC+wwaNdDQRTFaoCEYYrfCMbuVkhL3Lgqbi+p5d5I1lSg== + dependencies: + "@types/node" "*" + "@types/parse-json@^4.0.0": version "4.0.0" resolved "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.0.tgz#2f8bb441434d163b35fb8ffdccd7138927ffb8c0" @@ -2187,6 +2329,13 @@ dependencies: "@types/yargs-parser" "*" +"@types/yargs@^17.0.13": + version "17.0.13" + resolved "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.13.tgz#34cced675ca1b1d51fcf4d34c3c6f0fa142a5c76" + integrity sha512-9sWaruZk2JGxIQU+IhI1fhPYRcQ0UuTNuKuCW9bR5fp7qi2Llf7WDzNa17Cy7TKnh3cdxDOiyTu6gaLS0eDatg== + dependencies: + "@types/yargs-parser" "*" + "@types/yarnpkg__lockfile@^1.1.5": version "1.1.5" resolved "https://registry.npmjs.org/@types/yarnpkg__lockfile/-/yarnpkg__lockfile-1.1.5.tgz#9639020e1fb65120a2f4387db8f1e8b63efdf229" @@ -2368,7 +2517,7 @@ abab@^2.0.3, abab@^2.0.5: resolved "https://registry.npmjs.org/abab/-/abab-2.0.6.tgz#41b80f2c871d19686216b82309231cfd3cb3d291" integrity sha512-j2afSsaIENvHZN2B8GOpF566vZ5WVk5opAiMTvWgaQT8DkbOqsTfvNAvHoRGU2zzP8cPoqys+xHTRDWW8L+/BA== -abbrev@1, abbrev@^1.0.0: +abbrev@1, abbrev@^1.0.0, abbrev@~1.1.1: version "1.1.1" resolved "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8" integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q== @@ -2491,7 +2640,7 @@ ansi-styles@^3.2.1: dependencies: color-convert "^1.9.0" -ansi-styles@^4.0.0, ansi-styles@^4.1.0: +ansi-styles@^4.0.0, ansi-styles@^4.1.0, ansi-styles@^4.3.0: version "4.3.0" resolved "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== @@ -2567,7 +2716,7 @@ archiver@^5.3.1: tar-stream "^2.2.0" zip-stream "^4.1.0" -archy@^1.0.0: +archy@^1.0.0, archy@~1.0.0: version "1.0.0" resolved "https://registry.npmjs.org/archy/-/archy-1.0.0.tgz#f9c8c13757cc1dd7bc379ac77b2c62a5c2868c40" integrity sha512-Xg+9RwCg/0p32teKdGMPTPnVXKD0w3DfHnFTficozsAgsvq2XenPJq/MYpzzQ/v8zrOyJn6Ds39VA4JIDwFfqw== @@ -2872,7 +3021,19 @@ before-after-hook@^2.2.0: resolved "https://registry.npmjs.org/before-after-hook/-/before-after-hook-2.2.3.tgz#c51e809c81a4e354084422b9b26bad88249c517c" integrity sha512-NzUnlZexiaH/46WDhANlyR2bXRopNg4F/zuSA3OpZnllCUgRaOF2znDioDWrmbNVsuZk6l9pMquQB38cfBZwkQ== -binary-extensions@^2.0.0: +bin-links@^3.0.3: + version "3.0.3" + resolved "https://registry.npmjs.org/bin-links/-/bin-links-3.0.3.tgz#3842711ef3db2cd9f16a5f404a996a12db355a6e" + integrity sha512-zKdnMPWEdh4F5INR07/eBrodC7QrF5JKvqskjz/ZZRXg5YSAZIbn8zGhbhUrElzHBZ2fvEQdOU59RHcTG3GiwA== + dependencies: + cmd-shim "^5.0.0" + mkdirp-infer-owner "^2.0.0" + npm-normalize-package-bin "^2.0.0" + read-cmd-shim "^3.0.0" + rimraf "^3.0.0" + write-file-atomic "^4.0.0" + +binary-extensions@^2.0.0, binary-extensions@^2.2.0: version "2.2.0" resolved "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz#75f502eeaf9ffde42fc98829645be4ea76bd9e2d" integrity sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA== @@ -3034,7 +3195,7 @@ cacache@^15.0.5, cacache@^15.2.0: tar "^6.0.2" unique-filename "^1.1.1" -cacache@^16.0.0, cacache@^16.1.0: +cacache@^16.0.0, cacache@^16.1.0, cacache@^16.1.3: version "16.1.3" resolved "https://registry.npmjs.org/cacache/-/cacache-16.1.3.tgz#a02b9f34ecfaf9a78c9f4bc16fceb94d5d67a38e" integrity sha512-/+Emcj9DAXxX4cwlLmRI9c166RuL3w30zp4R7Joiv2cQTtTtA+jeuCAjH3ZlGnYS3tKENSrKhAzVVP9GVyzeYQ== @@ -3231,6 +3392,13 @@ ci-info@^3.2.0: resolved "https://registry.npmjs.org/ci-info/-/ci-info-3.7.1.tgz#708a6cdae38915d597afdf3b145f2f8e1ff55f3f" integrity sha512-4jYS4MOAaCIStSRwiuxc4B8MYhIe676yO1sYGzARnjXkWpmzZMMYxY6zu8WYWDhSuth5zhrQ1rhNSibyyvv4/w== +cidr-regex@^3.1.1: + version "3.1.1" + resolved "https://registry.npmjs.org/cidr-regex/-/cidr-regex-3.1.1.tgz#ba1972c57c66f61875f18fd7dd487469770b571d" + integrity sha512-RBqYd32aDwbCMFJRL6wHOlDNYJsPNTt8vC82ErHF5vKt8QQzxm1FrkW8s/R5pVrXMf17sba09Uoy91PKiddAsw== + dependencies: + ip-regex "^4.1.0" + cint@^8.2.1: version "8.2.1" resolved "https://registry.npmjs.org/cint/-/cint-8.2.1.tgz#70386b1b48e2773d0d63166a55aff94ef4456a12" @@ -3262,6 +3430,14 @@ cli-color@^2.0.0: memoizee "^0.4.15" timers-ext "^0.1.7" +cli-columns@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/cli-columns/-/cli-columns-4.0.0.tgz#9fe4d65975238d55218c41bd2ed296a7fa555646" + integrity sha512-XW2Vg+w+L9on9wtwKpyzluIPCWXjaBahI7mTcYjx+BVIYD9c3yqcv/yKC7CmdCZat4rq2yiE1UMSJC5ivKfMtQ== + dependencies: + string-width "^4.2.3" + strip-ansi "^6.0.1" + cli-cursor@^3.1.0: version "3.1.0" resolved "https://registry.npmjs.org/cli-cursor/-/cli-cursor-3.1.0.tgz#264305a7ae490d1d03bf0c9ba7c925d1753af307" @@ -3274,6 +3450,15 @@ cli-spinners@^2.5.0: resolved "https://registry.npmjs.org/cli-spinners/-/cli-spinners-2.7.0.tgz#f815fd30b5f9eaac02db604c7a231ed7cb2f797a" integrity sha512-qu3pN8Y3qHNgE2AFweciB1IfMnmZ/fsNTEE+NOFjmGB2F/7rLhnhzppvpCnN4FovtP26k8lHyy9ptEbNwWFLzw== +cli-table3@^0.6.2: + version "0.6.3" + resolved "https://registry.npmjs.org/cli-table3/-/cli-table3-0.6.3.tgz#61ab765aac156b52f222954ffc607a6f01dbeeb2" + integrity sha512-w5Jac5SykAeZJKntOxJCrm63Eg5/4dhMWIcuTbo9rpE+brgaSZo0RuNJZeOyMgsUdhDeojvgyQLmjI+K50ZGyg== + dependencies: + string-width "^4.2.0" + optionalDependencies: + "@colors/colors" "1.5.0" + cli-table@^0.3.11: version "0.3.11" resolved "https://registry.npmjs.org/cli-table/-/cli-table-0.3.11.tgz#ac69cdecbe81dccdba4889b9a18b7da312a9d3ee" @@ -3346,6 +3531,13 @@ cmd-shim@^4.1.0: dependencies: mkdirp-infer-owner "^2.0.0" +cmd-shim@^5.0.0: + version "5.0.0" + resolved "https://registry.npmjs.org/cmd-shim/-/cmd-shim-5.0.0.tgz#8d0aaa1a6b0708630694c4dbde070ed94c707724" + integrity sha512-qkCtZ59BidfEwHltnJwkyVZn+XQojdAySM1D1gSeh11Z4pW1Kpolkyo53L5noc0nrxmIvyFwTmJRo4xs7FFLPw== + dependencies: + mkdirp-infer-owner "^2.0.0" + co@^4.6.0: version "4.6.0" resolved "https://registry.npmjs.org/co/-/co-4.6.0.tgz#6ea6bdf3d853ae54ccb8e47bfa0bf3f9031fb184" @@ -3399,7 +3591,7 @@ colors@1.0.3, colors@1.4.0: resolved "https://registry.npmjs.org/colors/-/colors-1.4.0.tgz#c50491479d4c1bdaed2c9ced32cf7c7dc2360f78" integrity sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA== -columnify@^1.5.4: +columnify@^1.5.4, columnify@^1.6.0: version "1.6.0" resolved "https://registry.npmjs.org/columnify/-/columnify-1.6.0.tgz#6989531713c9008bb29735e61e37acf5bd553cf3" integrity sha512-lomjuFZKfM6MSAnV9aCZC9sc0qGbmZdfygNv+nCpqVkSKdCxCklLtd16O0EILGkImHw9ZpHkAnHaB+8Zxq5W6Q== @@ -3440,6 +3632,11 @@ comment-json@4.2.2: has-own-prop "^2.0.0" repeat-string "^1.6.1" +common-ancestor-path@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/common-ancestor-path/-/common-ancestor-path-1.0.1.tgz#4f7d2d1394d91b7abdf51871c62f71eadb0182a7" + integrity sha512-L3sHRo1pXXEqX8VU28kfgUY+YGsk09hPqZiZmLacNib6XNTCM8ubYeT7ryXQw8asB1sKgcU5lkB7ONug08aB8w== + commondir@^1.0.1: version "1.0.1" resolved "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz#ddd800da0c66127393cca5950ea968a3aaf1253b" @@ -3782,6 +3979,11 @@ crypto-random-string@^2.0.0: resolved "https://registry.npmjs.org/crypto-random-string/-/crypto-random-string-2.0.0.tgz#ef2a7a966ec11083388369baa02ebead229b30d5" integrity sha512-v1plID3y9r/lPhviJ1wrXpLeyUIGAZ2SHNYTEapm7/8A9nLPoyvVp3RK/EPFqn5kEznyWgYZNsRtYYIWbuG8KA== +cssesc@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/cssesc/-/cssesc-3.0.0.tgz#37741919903b868565e1c09ea747445cd18983ee" + integrity sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg== + cssom@^0.4.4: version "0.4.4" resolved "https://registry.npmjs.org/cssom/-/cssom-0.4.4.tgz#5a66cf93d2d0b661d80bf6a44fb65f5c2e4e0a10" @@ -4554,11 +4756,6 @@ eslint-plugin-promise@^4.3.1: resolved "https://registry.npmjs.org/eslint-plugin-promise/-/eslint-plugin-promise-4.3.1.tgz#61485df2a359e03149fdafc0a68b0e030ad2ac45" integrity sha512-bY2sGqyptzFBDLh/GMbAxfdJC+b0f23ME63FOE4+Jao0oZ3E1LEwFtWJX/1pGMJLiTtrSSern2CRM/g+dfc0eQ== -eslint-plugin-rulesdir@0.2.1: - version "0.2.1" - resolved "https://registry.npmjs.org/eslint-plugin-rulesdir/-/eslint-plugin-rulesdir-0.2.1.tgz#e246bb9657e68eb0a30680c60775f40aa829ec0b" - integrity sha512-t7rQvEyfE4JZJu6dPl4/uVr6Fr0fxopBhzVbtq3isfOHMKdlIe9xW/5CtIaWZI0E1U+wzAk0lEnZC8laCD5YLA== - eslint-plugin-standard@^4.1.0: version "4.1.0" resolved "https://registry.npmjs.org/eslint-plugin-standard/-/eslint-plugin-standard-4.1.0.tgz#0c3bf3a67e853f8bbbc580fb4945fbf16f41b7c5" @@ -4874,6 +5071,11 @@ fast-memoize@^2.5.2: resolved "https://registry.npmjs.org/fast-memoize/-/fast-memoize-2.5.2.tgz#79e3bb6a4ec867ea40ba0e7146816f6cdce9b57e" integrity sha512-Ue0LwpDYErFbmNnZSF0UH6eImUwDmogUO1jyE+JbN2gsQz/jICm1Ve7t9QT0rNSsfJt+Hs4/S3GnsDVjL4HVrw== +fastest-levenshtein@^1.0.12: + version "1.0.16" + resolved "https://registry.npmjs.org/fastest-levenshtein/-/fastest-levenshtein-1.0.16.tgz#210e61b6ff181de91ea9b3d1b84fdedd47e034e5" + integrity sha512-eRnCtTTtGZFpQCwhJiUOuxPQWRXVKYDn0b2PeHfXL6/Zi53SLAzAHfVhVWK2AryC/WH05kGfxhFIPvTF0SXQzg== + fastq@^1.6.0: version "1.15.0" resolved "https://registry.npmjs.org/fastq/-/fastq-1.15.0.tgz#d04d07c6a2a68fe4599fea8d2e103a937fae6b3a" @@ -5579,7 +5781,7 @@ hosted-git-info@^4.0.0, hosted-git-info@^4.0.1: dependencies: lru-cache "^6.0.0" -hosted-git-info@^5.0.0: +hosted-git-info@^5.0.0, hosted-git-info@^5.2.1: version "5.2.1" resolved "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-5.2.1.tgz#0ba1c97178ef91f3ab30842ae63d6a272341156f" integrity sha512-xIcQYMnhcx2Nr4JTjsFmwwnr9vldugPy9uVm0o87bjqqWMv9GaqsTeT+i99wTl0mk1uLxJtHxLb8kymqTENQsw== @@ -5778,7 +5980,7 @@ ini@^1.3.2, ini@^1.3.4, ini@^1.3.5, ini@~1.3.0: resolved "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz#a29da425b48806f34767a4efce397269af28432c" integrity sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew== -ini@~3.0.0: +ini@^3.0.0, ini@~3.0.0: version "3.0.1" resolved "https://registry.npmjs.org/ini/-/ini-3.0.1.tgz#c76ec81007875bc44d544ff7a11a55d12294102d" integrity sha512-it4HyVAUTKBc6m8e1iXWvXSTdndF7HbdN713+kvLrymxTaU4AUBWrJ4vEooP+V7fexnVD3LKcBshjGGPefSMUQ== @@ -5796,6 +5998,19 @@ init-package-json@^2.0.2: validate-npm-package-license "^3.0.4" validate-npm-package-name "^3.0.0" +init-package-json@^3.0.2: + version "3.0.2" + resolved "https://registry.npmjs.org/init-package-json/-/init-package-json-3.0.2.tgz#f5bc9bac93f2bdc005778bc2271be642fecfcd69" + integrity sha512-YhlQPEjNFqlGdzrBfDNRLhvoSgX7iQRgSxgsNknRQ9ITXFT7UMfVMWhBTOh2Y+25lRnGrv5Xz8yZwQ3ACR6T3A== + dependencies: + npm-package-arg "^9.0.1" + promzard "^0.3.0" + read "^1.0.7" + read-package-json "^5.0.0" + semver "^7.3.5" + validate-npm-package-license "^3.0.4" + validate-npm-package-name "^4.0.0" + inquirer@^7.3.3: version "7.3.3" resolved "https://registry.npmjs.org/inquirer/-/inquirer-7.3.3.tgz#04d176b2af04afc157a83fd7c100e98ee0aad003" @@ -5829,6 +6044,11 @@ interpret@^1.0.0: resolved "https://registry.npmjs.org/interpret/-/interpret-1.4.0.tgz#665ab8bc4da27a774a40584e812e3e0fa45b1a1e" integrity sha512-agE4QfB2Lkp9uICn7BAqoscw4SZP9kTE2hxiFI3jBPmXJfdqiahTbUuKGsMoN2GtqL9AxhYioAcVvgsb1HvRbA== +ip-regex@^4.1.0: + version "4.3.0" + resolved "https://registry.npmjs.org/ip-regex/-/ip-regex-4.3.0.tgz#687275ab0f57fa76978ff8f4dddc8a23d5990db5" + integrity sha512-B9ZWJxHHOHUhUjCPrMpLD4xEq35bUTClHM1S6CBU5ixQnkZmwipwgc96vAd7AAGM9TGHvJR+Uss+/Ak6UphK+Q== + ip@^1.1.5: version "1.1.8" resolved "https://registry.npmjs.org/ip/-/ip-1.1.8.tgz#ae05948f6b075435ed3307acce04629da8cdbf48" @@ -5891,6 +6111,13 @@ is-ci@^2.0.0: dependencies: ci-info "^2.0.0" +is-cidr@^4.0.2: + version "4.0.2" + resolved "https://registry.npmjs.org/is-cidr/-/is-cidr-4.0.2.tgz#94c7585e4c6c77ceabf920f8cde51b8c0fda8814" + integrity sha512-z4a1ENUajDbEl/Q6/pVBpTR1nBjjEE1X7qb7bmWYanNnPoKAvUCPFKeXV6Fe4mgTkWKBqiHIcwsI3SndiO5FeA== + dependencies: + cidr-regex "^3.1.1" + is-core-module@^2.5.0, is-core-module@^2.8.1, is-core-module@^2.9.0: version "2.11.0" resolved "https://registry.npmjs.org/is-core-module/-/is-core-module-2.11.0.tgz#ad4cb3e3863e814523c96f3f58d26cc570ff0144" @@ -6448,6 +6675,16 @@ jest-junit@^13, jest-junit@^13.2.0: uuid "^8.3.2" xml "^1.0.1" +jest-junit@^14.0.0: + version "14.0.1" + resolved "https://registry.npmjs.org/jest-junit/-/jest-junit-14.0.1.tgz#5b357d6f5d333459585d628a24cd48b5bbc92ba2" + integrity sha512-h7/wwzPbllgpQhhVcRzRC76/cc89GlazThoV1fDxcALkf26IIlRsu/AcTG64f4nR2WPE3Cbd+i/sVf+NCUHrWQ== + dependencies: + mkdirp "^1.0.4" + strip-ansi "^6.0.1" + uuid "^8.3.2" + xml "^1.0.1" + jest-leak-detector@^27.5.1: version "27.5.1" resolved "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-27.5.1.tgz#6ec9d54c3579dd6e3e66d70e3498adf80fde3fb8" @@ -6886,6 +7123,11 @@ json-stable-stringify-without-jsonify@^1.0.1: resolved "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" integrity sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw== +json-stringify-nice@^1.1.4: + version "1.1.4" + resolved "https://registry.npmjs.org/json-stringify-nice/-/json-stringify-nice-1.1.4.tgz#2c937962b80181d3f317dd39aa323e14f5a60a67" + integrity sha512-5Z5RFW63yxReJ7vANgW6eZFGWaQvnPE3WNmZoOJrSkGju2etKA2L5rrOa1sm877TVTFt57A80BH1bArcmlLfPw== + json-stringify-safe@^5.0.1, json-stringify-safe@~5.0.1: version "5.0.1" resolved "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" @@ -6959,6 +7201,16 @@ jszip@^3.10.1: readable-stream "~2.3.6" setimmediate "^1.0.5" +just-diff-apply@^5.2.0: + version "5.5.0" + resolved "https://registry.npmjs.org/just-diff-apply/-/just-diff-apply-5.5.0.tgz#771c2ca9fa69f3d2b54e7c3f5c1dfcbcc47f9f0f" + integrity sha512-OYTthRfSh55WOItVqwpefPtNt2VdKsq5AnAK6apdtR6yCH8pr0CmSr710J0Mf+WdQy7K/OzMy7K2MgAfdQURDw== + +just-diff@^5.0.1: + version "5.2.0" + resolved "https://registry.npmjs.org/just-diff/-/just-diff-5.2.0.tgz#60dca55891cf24cd4a094e33504660692348a241" + integrity sha512-6ufhP9SHjb7jibNFrNxyFZ6od3g+An6Ai9mhGRvcYe8UJlH0prseN64M+6ZBBUoKYHZsitDP42gAJ8+eVWr3lw== + just-extend@^4.0.2: version "4.2.1" resolved "https://registry.npmjs.org/just-extend/-/just-extend-4.2.1.tgz#ef5e589afb61e5d66b24eca749409a8939a8c744" @@ -7075,6 +7327,16 @@ libnpmaccess@^4.0.1: npm-package-arg "^8.1.2" npm-registry-fetch "^11.0.0" +libnpmaccess@^6.0.2: + version "6.0.4" + resolved "https://registry.npmjs.org/libnpmaccess/-/libnpmaccess-6.0.4.tgz#2dd158bd8a071817e2207d3b201d37cf1ad6ae6b" + integrity sha512-qZ3wcfIyUoW0+qSFkMBovcTrSGJ3ZeyvpR7d5N9pEYv/kXs8sHP2wiqEIXBKLFrZlmM0kR0RJD7mtfLngtlLag== + dependencies: + aproba "^2.0.0" + minipass "^3.1.1" + npm-package-arg "^9.0.1" + npm-registry-fetch "^13.0.0" + libnpmconfig@^1.2.1: version "1.2.1" resolved "https://registry.npmjs.org/libnpmconfig/-/libnpmconfig-1.2.1.tgz#c0c2f793a74e67d4825e5039e7a02a0044dfcbc0" @@ -7084,6 +7346,72 @@ libnpmconfig@^1.2.1: find-up "^3.0.0" ini "^1.3.5" +libnpmdiff@^4.0.2: + version "4.0.5" + resolved "https://registry.npmjs.org/libnpmdiff/-/libnpmdiff-4.0.5.tgz#ffaf93fa9440ea759444b8830fdb5c661b09a7c0" + integrity sha512-9fICQIzmH892UwHHPmb+Seup50UIBWcMIK2FdxvlXm9b4kc1nSH0b/BuY1mORJQtB6ydPMnn+BLzOTmd/SKJmw== + dependencies: + "@npmcli/disparity-colors" "^2.0.0" + "@npmcli/installed-package-contents" "^1.0.7" + binary-extensions "^2.2.0" + diff "^5.1.0" + minimatch "^5.0.1" + npm-package-arg "^9.0.1" + pacote "^13.6.1" + tar "^6.1.0" + +libnpmexec@^4.0.2: + version "4.0.14" + resolved "https://registry.npmjs.org/libnpmexec/-/libnpmexec-4.0.14.tgz#9ad44232434b374e477eb2c2e4548baaf698f773" + integrity sha512-dwmzv2K29SdoAHBOa7QR6CfQbFG/PiZDRF6HZrlI6C4DLt2hNgOHTFaUGOpqE2C+YGu0ZwYTDywxRe0eOnf0ZA== + dependencies: + "@npmcli/arborist" "^5.6.3" + "@npmcli/ci-detect" "^2.0.0" + "@npmcli/fs" "^2.1.1" + "@npmcli/run-script" "^4.2.0" + chalk "^4.1.0" + mkdirp-infer-owner "^2.0.0" + npm-package-arg "^9.0.1" + npmlog "^6.0.2" + pacote "^13.6.1" + proc-log "^2.0.0" + read "^1.0.7" + read-package-json-fast "^2.0.2" + semver "^7.3.7" + walk-up-path "^1.0.0" + +libnpmfund@^3.0.1: + version "3.0.5" + resolved "https://registry.npmjs.org/libnpmfund/-/libnpmfund-3.0.5.tgz#817f9e2120889beb483d9ba8eda142bb84293e4e" + integrity sha512-KdeRoG/dem8H3PcEU2/0SKi3ip7AWwczgS72y/3PE+PBrz/s/G52FNIA9jeLnBirkLC0sOyQHfeM3b7e24ZM+g== + dependencies: + "@npmcli/arborist" "^5.6.3" + +libnpmhook@^8.0.2: + version "8.0.4" + resolved "https://registry.npmjs.org/libnpmhook/-/libnpmhook-8.0.4.tgz#6c58e5fe763ff5d600ae9c20457ea9a69d1f7d87" + integrity sha512-nuD6e+Nx0OprjEi0wOeqASMl6QIH235th/Du2/8upK3evByFhzIgdfOeP1OhstavW4xtsl0hk5Vw4fAWWuSUgA== + dependencies: + aproba "^2.0.0" + npm-registry-fetch "^13.0.0" + +libnpmorg@^4.0.2: + version "4.0.4" + resolved "https://registry.npmjs.org/libnpmorg/-/libnpmorg-4.0.4.tgz#2a01d49372cf0df90d79a61e69bddaf2ed704311" + integrity sha512-1bTpD7iub1rDCsgiBguhJhiDufLQuc8DEti20euqsXz9O0ncXVpCYqf2SMmHR4GEdmAvAj2r7FMiyA9zGdaTpA== + dependencies: + aproba "^2.0.0" + npm-registry-fetch "^13.0.0" + +libnpmpack@^4.0.2: + version "4.1.3" + resolved "https://registry.npmjs.org/libnpmpack/-/libnpmpack-4.1.3.tgz#025cfe39829acd8260662bf259e3a9331fc1e4b2" + integrity sha512-rYP4X++ME3ZiFO+2iN3YnXJ4LB4Gsd0z5cgszWJZxaEpDN4lRIXirSyynGNsN/hn4taqnlxD+3DPlFDShvRM8w== + dependencies: + "@npmcli/run-script" "^4.1.3" + npm-package-arg "^9.0.1" + pacote "^13.6.1" + libnpmpublish@^4.0.0: version "4.0.2" resolved "https://registry.npmjs.org/libnpmpublish/-/libnpmpublish-4.0.2.tgz#be77e8bf5956131bcb45e3caa6b96a842dec0794" @@ -7095,6 +7423,43 @@ libnpmpublish@^4.0.0: semver "^7.1.3" ssri "^8.0.1" +libnpmpublish@^6.0.2: + version "6.0.5" + resolved "https://registry.npmjs.org/libnpmpublish/-/libnpmpublish-6.0.5.tgz#5a894f3de2e267d62f86be2a508e362599b5a4b1" + integrity sha512-LUR08JKSviZiqrYTDfywvtnsnxr+tOvBU0BF8H+9frt7HMvc6Qn6F8Ubm72g5hDTHbq8qupKfDvDAln2TVPvFg== + dependencies: + normalize-package-data "^4.0.0" + npm-package-arg "^9.0.1" + npm-registry-fetch "^13.0.0" + semver "^7.3.7" + ssri "^9.0.0" + +libnpmsearch@^5.0.2: + version "5.0.4" + resolved "https://registry.npmjs.org/libnpmsearch/-/libnpmsearch-5.0.4.tgz#b32aa2b23051c00cdcc0912274d0d416e6655d81" + integrity sha512-XHDmsvpN5+pufvGnfLRqpy218gcGGbbbXR6wPrDJyd1em6agKdYByzU5ccskDHH9iVm2UeLydpDsW1ksYuU0cg== + dependencies: + npm-registry-fetch "^13.0.0" + +libnpmteam@^4.0.2: + version "4.0.4" + resolved "https://registry.npmjs.org/libnpmteam/-/libnpmteam-4.0.4.tgz#ac26068808d93b1051d926457db14e4b3ff669ef" + integrity sha512-rzKSwi6MLzwwevbM/vl+BBQTErgn24tCfgPUdzBlszrw3j5necOu7WnTzgvZMDv6maGUwec6Ut1rxszOgH0l+Q== + dependencies: + aproba "^2.0.0" + npm-registry-fetch "^13.0.0" + +libnpmversion@^3.0.1: + version "3.0.7" + resolved "https://registry.npmjs.org/libnpmversion/-/libnpmversion-3.0.7.tgz#e4c6c07ee28cf351ce1e2293a5ac9922b09ea94d" + integrity sha512-O0L4eNMUIMQ+effi1HsZPKp2N6wecwqGqB8PvkvmLPWN7EsdabdzAVG48nv0p/OjlbIai5KQg/L+qMMfCA4ZjA== + dependencies: + "@npmcli/git" "^3.0.0" + "@npmcli/run-script" "^4.1.3" + json-parse-even-better-errors "^2.3.1" + proc-log "^2.0.0" + semver "^7.3.7" + license-checker@^25.0.1: version "25.0.1" resolved "https://registry.npmjs.org/license-checker/-/license-checker-25.0.1.tgz#4d14504478a5240a857bb3c21cd0491a00d761fa" @@ -7368,7 +7733,7 @@ make-error@1.x, make-error@^1.1.1: resolved "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz#2eb2e37ea9b67c4891f684a1394799af484cf7a2" integrity sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw== -make-fetch-happen@^10.0.3, make-fetch-happen@^10.0.6: +make-fetch-happen@^10.0.3, make-fetch-happen@^10.0.6, make-fetch-happen@^10.1.5: version "10.2.1" resolved "https://registry.npmjs.org/make-fetch-happen/-/make-fetch-happen-10.2.1.tgz#f5e3835c5e9817b617f2770870d9492d28678164" integrity sha512-NgOPbRiaQM10DYXvN3/hhGVI2M5MtITFryzBGxHM5p4wnFxsVCbxkrBrDsk+EZ5OB4jEOT7AjDxtdF+KVEFT7w== @@ -7411,7 +7776,7 @@ make-fetch-happen@^8.0.9: socks-proxy-agent "^5.0.0" ssri "^8.0.0" -make-fetch-happen@^9.0.1: +make-fetch-happen@^9.0.1, make-fetch-happen@^9.1.0: version "9.1.0" resolved "https://registry.npmjs.org/make-fetch-happen/-/make-fetch-happen-9.1.0.tgz#53085a09e7971433e6765f7971bf63f4e05cb968" integrity sha512-+zopwDy7DNknmwPQplem5lAZX/eCOzSvSNNcSKm5eVwTkOBzoktEfXsa9L23J/GIRhxRsaxzkPEhrJEpE2F4Gg== @@ -7790,7 +8155,7 @@ ms@2.1.2: resolved "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== -ms@^2.0.0, ms@^2.1.1: +ms@^2.0.0, ms@^2.1.1, ms@^2.1.2: version "2.1.3" resolved "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== @@ -7923,6 +8288,22 @@ node-gyp@^7.1.0: tar "^6.0.2" which "^2.0.2" +node-gyp@^8.4.1: + version "8.4.1" + resolved "https://registry.npmjs.org/node-gyp/-/node-gyp-8.4.1.tgz#3d49308fc31f768180957d6b5746845fbd429937" + integrity sha512-olTJRgUtAb/hOXG0E93wZDs5YiJlgbXxTwQAFHyNlRsXQnYzUaF2aGgujZbw+hR8aF4ZG/rST57bWMWD16jr9w== + dependencies: + env-paths "^2.2.0" + glob "^7.1.4" + graceful-fs "^4.2.6" + make-fetch-happen "^9.1.0" + nopt "^5.0.0" + npmlog "^6.0.0" + rimraf "^3.0.2" + semver "^7.3.5" + tar "^6.1.2" + which "^2.0.2" + node-gyp@^9.0.0: version "9.3.1" resolved "https://registry.npmjs.org/node-gyp/-/node-gyp-9.3.1.tgz#1e19f5f290afcc9c46973d68700cbd21a96192e4" @@ -8030,6 +8411,13 @@ normalize-url@^6.1.0: resolved "https://registry.npmjs.org/normalize-url/-/normalize-url-6.1.0.tgz#40d0885b535deffe3f3147bec877d05fe4c5668a" integrity sha512-DlL+XwOy3NxAQ8xuC0okPgK46iuVNAK01YN7RueYBqqFeGsBjV9XmCAzAdgt+667bCl5kPh9EqKKDwnaPG1I7A== +npm-audit-report@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/npm-audit-report/-/npm-audit-report-3.0.0.tgz#1bf3e531208b5f77347c8d00c3d9badf5be30cd6" + integrity sha512-tWQzfbwz1sc4244Bx2BVELw0EmZlCsCF0X93RDcmmwhonCsPMoEviYsi+32R+mdRvOWXolPce9zo64n2xgPESw== + dependencies: + chalk "^4.0.0" + npm-bundled@^1.1.1, npm-bundled@^1.1.2: version "1.1.2" resolved "https://registry.npmjs.org/npm-bundled/-/npm-bundled-1.1.2.tgz#944c78789bd739035b70baa2ca5cc32b8d860bc1" @@ -8126,7 +8514,7 @@ npm-package-arg@^8.0.0, npm-package-arg@^8.0.1, npm-package-arg@^8.1.0, npm-pack semver "^7.3.4" validate-npm-package-name "^3.0.0" -npm-package-arg@^9.0.0, npm-package-arg@^9.0.1: +npm-package-arg@^9.0.0, npm-package-arg@^9.0.1, npm-package-arg@^9.0.2, npm-package-arg@^9.1.0: version "9.1.2" resolved "https://registry.npmjs.org/npm-package-arg/-/npm-package-arg-9.1.2.tgz#fc8acecb00235f42270dda446f36926ddd9ac2bc" integrity sha512-pzd9rLEx4TfNJkovvlBSLGhq31gGu2QDexFPWT19yCDh0JgnRhlBLNo5759N0AJmBk+kQ9Y/hXoLnlgFD+ukmg== @@ -8166,7 +8554,7 @@ npm-pick-manifest@^6.0.0, npm-pick-manifest@^6.1.1: npm-package-arg "^8.1.2" semver "^7.3.4" -npm-pick-manifest@^7.0.0: +npm-pick-manifest@^7.0.0, npm-pick-manifest@^7.0.1, npm-pick-manifest@^7.0.2: version "7.0.2" resolved "https://registry.npmjs.org/npm-pick-manifest/-/npm-pick-manifest-7.0.2.tgz#1d372b4e7ea7c6712316c0e99388a73ed3496e84" integrity sha512-gk37SyRmlIjvTfcYl6RzDbSmS9Y4TOBXfsPnoYqTHARNgWbyDiCSMLUpmALDj4jjcTZpURiEfsSHJj9k7EV4Rw== @@ -8176,6 +8564,14 @@ npm-pick-manifest@^7.0.0: npm-package-arg "^9.0.0" semver "^7.3.5" +npm-profile@^6.0.3: + version "6.2.1" + resolved "https://registry.npmjs.org/npm-profile/-/npm-profile-6.2.1.tgz#975c31ec75a6ae029ab5b8820ffdcbae3a1e3d5e" + integrity sha512-Tlu13duByHyDd4Xy0PgroxzxnBYWbGGL5aZifNp8cx2DxUrHSoETXtPKg38aRPsBWMRfDtvcvVfJNasj7oImQQ== + dependencies: + npm-registry-fetch "^13.0.1" + proc-log "^2.0.0" + npm-registry-fetch@^11.0.0: version "11.0.0" resolved "https://registry.npmjs.org/npm-registry-fetch/-/npm-registry-fetch-11.0.0.tgz#68c1bb810c46542760d62a6a965f85a702d43a76" @@ -8188,7 +8584,7 @@ npm-registry-fetch@^11.0.0: minizlib "^2.0.0" npm-package-arg "^8.0.0" -npm-registry-fetch@^13.0.1: +npm-registry-fetch@^13.0.0, npm-registry-fetch@^13.0.1, npm-registry-fetch@^13.1.1: version "13.3.1" resolved "https://registry.npmjs.org/npm-registry-fetch/-/npm-registry-fetch-13.3.1.tgz#bb078b5fa6c52774116ae501ba1af2a33166af7e" integrity sha512-eukJPi++DKRTjSBRcDZSDDsGqRK3ehbxfFUcgaRd0Yp6kRwOwh2WVn0r+8rMB4nnuzvAk6rQVzl6K5CkYOmnvw== @@ -8222,6 +8618,87 @@ npm-run-path@^4.0.1: dependencies: path-key "^3.0.0" +npm-user-validate@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/npm-user-validate/-/npm-user-validate-1.0.1.tgz#31428fc5475fe8416023f178c0ab47935ad8c561" + integrity sha512-uQwcd/tY+h1jnEaze6cdX/LrhWhoBxfSknxentoqmIuStxUExxjWd3ULMLFPiFUrZKbOVMowH6Jq2FRWfmhcEw== + +npm@^8.11.0: + version "8.11.0" + resolved "https://registry.npmjs.org/npm/-/npm-8.11.0.tgz#224fbca389252e43dd2a277249df3320a7f91189" + integrity sha512-4qmtwHa28J4SPmwCNoQI07KIF/ljmBhhuqG+xNXsIIRpwdKB5OXkMIGfH6KlThR6kzusxlkgR7t1haFDB88dcQ== + dependencies: + "@isaacs/string-locale-compare" "^1.1.0" + "@npmcli/arborist" "^5.0.4" + "@npmcli/ci-detect" "^2.0.0" + "@npmcli/config" "^4.1.0" + "@npmcli/fs" "^2.1.0" + "@npmcli/map-workspaces" "^2.0.3" + "@npmcli/package-json" "^2.0.0" + "@npmcli/run-script" "^3.0.1" + abbrev "~1.1.1" + archy "~1.0.0" + cacache "^16.1.0" + chalk "^4.1.2" + chownr "^2.0.0" + cli-columns "^4.0.0" + cli-table3 "^0.6.2" + columnify "^1.6.0" + fastest-levenshtein "^1.0.12" + glob "^8.0.1" + graceful-fs "^4.2.10" + hosted-git-info "^5.0.0" + ini "^3.0.0" + init-package-json "^3.0.2" + is-cidr "^4.0.2" + json-parse-even-better-errors "^2.3.1" + libnpmaccess "^6.0.2" + libnpmdiff "^4.0.2" + libnpmexec "^4.0.2" + libnpmfund "^3.0.1" + libnpmhook "^8.0.2" + libnpmorg "^4.0.2" + libnpmpack "^4.0.2" + libnpmpublish "^6.0.2" + libnpmsearch "^5.0.2" + libnpmteam "^4.0.2" + libnpmversion "^3.0.1" + make-fetch-happen "^10.1.5" + minipass "^3.1.6" + minipass-pipeline "^1.2.4" + mkdirp "^1.0.4" + mkdirp-infer-owner "^2.0.0" + ms "^2.1.2" + node-gyp "^9.0.0" + nopt "^5.0.0" + npm-audit-report "^3.0.0" + npm-install-checks "^5.0.0" + npm-package-arg "^9.0.2" + npm-pick-manifest "^7.0.1" + npm-profile "^6.0.3" + npm-registry-fetch "^13.1.1" + npm-user-validate "^1.0.1" + npmlog "^6.0.2" + opener "^1.5.2" + pacote "^13.4.1" + parse-conflict-json "^2.0.2" + proc-log "^2.0.1" + qrcode-terminal "^0.12.0" + read "~1.0.7" + read-package-json "^5.0.1" + read-package-json-fast "^2.0.3" + readdir-scoped-modules "^1.1.0" + rimraf "^3.0.2" + semver "^7.3.7" + ssri "^9.0.1" + tar "^6.1.11" + text-table "~0.2.0" + tiny-relative-date "^1.3.0" + treeverse "^2.0.0" + validate-npm-package-name "^4.0.0" + which "^2.0.2" + write-file-atomic "^4.0.1" + npmlog@^4.1.2: version "4.1.2" resolved "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz#08a7f2a8bf734604779a9efa4ad5cc717abb954b" @@ -8232,7 +8709,7 @@ npmlog@^4.1.2: gauge "~2.7.3" set-blocking "~2.0.0" -npmlog@^6.0.0: +npmlog@^6.0.0, npmlog@^6.0.2: version "6.0.2" resolved "https://registry.npmjs.org/npmlog/-/npmlog-6.0.2.tgz#c8166017a42f2dea92d6453168dd865186a70830" integrity sha512-/vBvz5Jfr9dT/aFWd0FIRf+T/Q2WBsLENygUaFUqstqsycmZAP/t5BvFJTK0viFmSUxiUKTUplWy5vt+rvKIxg== @@ -8356,6 +8833,11 @@ open@^7.4.2: is-docker "^2.0.0" is-wsl "^2.1.1" +opener@^1.5.2: + version "1.5.2" + resolved "https://registry.npmjs.org/opener/-/opener-1.5.2.tgz#5d37e1f35077b9dcac4301372271afdeb2a13598" + integrity sha512-ur5UIdyw5Y7yEj9wLzhqXiy6GZ3Mwx0yGI+5sMn2r0N0v3cKJvUmFH5yPP+WXh9e0xfyzyJX95D8l088DNFj7A== + optionator@^0.8.1: version "0.8.3" resolved "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz#84fa1d036fe9d3c7e21d99884b601167ec8fb495" @@ -8602,7 +9084,7 @@ pacote@^11.2.6: ssri "^8.0.1" tar "^6.1.0" -pacote@^13.0.5: +pacote@^13.0.3, pacote@^13.0.5, pacote@^13.4.1, pacote@^13.6.1: version "13.6.2" resolved "https://registry.npmjs.org/pacote/-/pacote-13.6.2.tgz#0d444ba3618ab3e5cd330b451c22967bbd0ca48a" integrity sha512-Gu8fU3GsvOPkak2CkbojR7vjs3k3P9cA6uazKTHdsdV0gpCEQq2opelnEv30KRQWgVzP5Vd/5umjcedma3MKtg== @@ -8641,6 +9123,15 @@ parent-module@^1.0.0: dependencies: callsites "^3.0.0" +parse-conflict-json@^2.0.1, parse-conflict-json@^2.0.2: + version "2.0.2" + resolved "https://registry.npmjs.org/parse-conflict-json/-/parse-conflict-json-2.0.2.tgz#3d05bc8ffe07d39600dc6436c6aefe382033d323" + integrity sha512-jDbRGb00TAPFsKWCpZZOT93SxVP9nONOSgES3AevqRq/CHvavEBvKAjxX9p5Y5F0RZLxH9Ufd9+RwtCsa+lFDA== + dependencies: + json-parse-even-better-errors "^2.3.1" + just-diff "^5.0.1" + just-diff-apply "^5.2.0" + parse-github-url@^1.0.2: version "1.0.2" resolved "https://registry.npmjs.org/parse-github-url/-/parse-github-url-1.0.2.tgz#242d3b65cbcdda14bb50439e3242acf6971db395" @@ -8820,6 +9311,14 @@ pluralize@^8.0.0: resolved "https://registry.npmjs.org/pluralize/-/pluralize-8.0.0.tgz#1a6fa16a38d12a1901e0320fa017051c539ce3b1" integrity sha512-Nc3IT5yHzflTfbjgqWcCPpo7DaKy4FnpB0l/zCAW0Tc7jxAiuqSxHasntB3D7887LSrA93kDJ9IXovxJYxyLCA== +postcss-selector-parser@^6.0.10: + version "6.0.11" + resolved "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-6.0.11.tgz#2e41dc39b7ad74046e1615185185cd0b17d0c8dc" + integrity sha512-zbARubNdogI9j7WY4nQJBiNqQf3sLS3wCP4WfOidu+p28LofJqDH1tcXypGrcmMHhDk2t9wGhCsYe/+szLTy1g== + dependencies: + cssesc "^3.0.0" + util-deprecate "^1.0.2" + postcss-values-parser@^2.0.1: version "2.0.1" resolved "https://registry.npmjs.org/postcss-values-parser/-/postcss-values-parser-2.0.1.tgz#da8b472d901da1e205b47bdc98637b9e9e550e5f" @@ -8950,6 +9449,16 @@ projen@^0.66.0: yargs "^16.2.0" zlib "^1.0.5" +promise-all-reject-late@^1.0.0: + version "1.0.1" + resolved "https://registry.npmjs.org/promise-all-reject-late/-/promise-all-reject-late-1.0.1.tgz#f8ebf13483e5ca91ad809ccc2fcf25f26f8643c2" + integrity sha512-vuf0Lf0lOxyQREH7GDIOUMLS7kz+gs8i6B+Yi8dC68a2sychGrHTJYghMBD6k7eUcH0H5P73EckCA48xijWqXw== + +promise-call-limit@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/promise-call-limit/-/promise-call-limit-1.0.1.tgz#4bdee03aeb85674385ca934da7114e9bcd3c6e24" + integrity sha512-3+hgaa19jzCGLuSCbieeRsu5C2joKfYn8pY6JAuXFRVfF4IO+L7UPpFWNTeWT9pM7uhskvbPPd/oEOktCn317Q== + promise-inflight@^1.0.1: version "1.0.1" resolved "https://registry.npmjs.org/promise-inflight/-/promise-inflight-1.0.1.tgz#98472870bf228132fcbdd868129bad12c3c029e3" @@ -9073,6 +9582,11 @@ q@^1.5.1: resolved "https://registry.npmjs.org/q/-/q-1.5.1.tgz#7e32f75b41381291d04611f1bf14109ac00651d7" integrity sha512-kV/CThkXo6xyFEZUugw/+pIOywXcDbFYgSct5cT3gqlbkBE1SJdwy6UQoZvodiWF/ckQLZyDE/Bu1M6gVu5lVw== +qrcode-terminal@^0.12.0: + version "0.12.0" + resolved "https://registry.npmjs.org/qrcode-terminal/-/qrcode-terminal-0.12.0.tgz#bb5b699ef7f9f0505092a3748be4464fe71b5819" + integrity sha512-EXtzRZmC+YGmGlDFbXKxQiMZNwCLEO6BANKXG4iCtSIM0yqc/pappSx3RIKr4r0uh5JsBckOXeKrB3Iz7mdQpQ== + qs@^6.9.4: version "6.11.0" resolved "https://registry.npmjs.org/qs/-/qs-6.11.0.tgz#fd0d963446f7a65e1367e01abd85429453f0c37a" @@ -9160,6 +9674,11 @@ read-cmd-shim@^2.0.0: resolved "https://registry.npmjs.org/read-cmd-shim/-/read-cmd-shim-2.0.0.tgz#4a50a71d6f0965364938e9038476f7eede3928d9" integrity sha512-HJpV9bQpkl6KwjxlJcBoqu9Ba0PQg8TqSNIOrulGt54a0uup0HtevreFHzYzkm0lpnleRdNBzXznKrgxglEHQw== +read-cmd-shim@^3.0.0: + version "3.0.1" + resolved "https://registry.npmjs.org/read-cmd-shim/-/read-cmd-shim-3.0.1.tgz#868c235ec59d1de2db69e11aec885bc095aea087" + integrity sha512-kEmDUoYf/CDy8yZbLTmhB1X9kkjf9Q80PCNsDMb7ufrGd6zZSQA1+UyjrO+pZm5K/S4OXCWJeiIt1JA8kAsa6g== + read-installed@~4.0.3: version "4.0.3" resolved "https://registry.npmjs.org/read-installed/-/read-installed-4.0.3.tgz#ff9b8b67f187d1e4c29b9feb31f6b223acd19067" @@ -9174,7 +9693,7 @@ read-installed@~4.0.3: optionalDependencies: graceful-fs "^4.1.2" -read-package-json-fast@^2.0.1, read-package-json-fast@^2.0.3: +read-package-json-fast@^2.0.1, read-package-json-fast@^2.0.2, read-package-json-fast@^2.0.3: version "2.0.3" resolved "https://registry.npmjs.org/read-package-json-fast/-/read-package-json-fast-2.0.3.tgz#323ca529630da82cb34b36cc0b996693c98c2b83" integrity sha512-W/BKtbL+dUjTuRL2vziuYhp76s5HZ9qQhd/dKfWIZveD0O40453QNyZhC0e63lqZrAQ4jiOapVoeJ7JrszenQQ== @@ -9212,7 +9731,7 @@ read-package-json@^4.1.1: normalize-package-data "^3.0.0" npm-normalize-package-bin "^1.0.0" -read-package-json@^5.0.0: +read-package-json@^5.0.0, read-package-json@^5.0.1: version "5.0.2" resolved "https://registry.npmjs.org/read-package-json/-/read-package-json-5.0.2.tgz#b8779ccfd169f523b67208a89cc912e3f663f3fa" integrity sha512-BSzugrt4kQ/Z0krro8zhTwV1Kd79ue25IhNN/VtHFy1mG/6Tluyi+msc0UpwaoQzxSHa28mntAjIZY6kEgfR9Q== @@ -9267,7 +9786,7 @@ read-pkg@^5.2.0: parse-json "^5.0.0" type-fest "^0.6.0" -read@1, read@^1.0.4, read@~1.0.1: +read@1, read@^1.0.4, read@^1.0.7, read@~1.0.1, read@~1.0.7: version "1.0.7" resolved "https://registry.npmjs.org/read/-/read-1.0.7.tgz#b3da19bd052431a97671d44a42634adf710b40c4" integrity sha512-rSOKNYUmaxy0om1BNjMN4ezNT6VKK+2xF4GBhc81mkH7L60i6dp8qPYrkndNLT3QPphoII3maL9PVC9XmhHwVQ== @@ -9313,7 +9832,7 @@ readdir-glob@^1.0.0: dependencies: minimatch "^5.1.0" -readdir-scoped-modules@^1.0.0: +readdir-scoped-modules@^1.0.0, readdir-scoped-modules@^1.1.0: version "1.1.0" resolved "https://registry.npmjs.org/readdir-scoped-modules/-/readdir-scoped-modules-1.1.0.tgz#8d45407b4f870a0dcaebc0e28670d18e74514309" integrity sha512-asaikDeqAQg7JifRsZn1NJZXo9E+VwlyCfbkZhwyISinqk5zNS6266HS5kah6P0SaQKGF6SkNnZVHUzHFYxYDw== @@ -9990,7 +10509,7 @@ ssri@^8.0.0, ssri@^8.0.1: dependencies: minipass "^3.1.1" -ssri@^9.0.0: +ssri@^9.0.0, ssri@^9.0.1: version "9.0.1" resolved "https://registry.npmjs.org/ssri/-/ssri-9.0.1.tgz#544d4c357a8d7b71a19700074b6883fcb4eae057" integrity sha512-o57Wcn66jMQvfHG1FlYbWeZWW/dHZhJXjpIcTfXldXEk5nz5lStPo3mK0OJQfGR3RbZUlbISexbljkJzuEj/8Q== @@ -10326,7 +10845,7 @@ text-extensions@^1.0.0: resolved "https://registry.npmjs.org/text-extensions/-/text-extensions-1.9.0.tgz#1853e45fee39c945ce6f6c36b2d659b5aabc2a26" integrity sha512-wiBrwC1EhBelW12Zy26JeOUkQ5mRu+5o8rpsJk5+2t+Y5vE7e842qtZDQ2g1NpX/29HdyFeJ4nSIhI47ENSxlQ== -text-table@^0.2.0: +text-table@^0.2.0, text-table@~0.2.0: version "0.2.0" resolved "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" integrity sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw== @@ -10364,6 +10883,11 @@ timers-ext@^0.1.7: es5-ext "~0.10.46" next-tick "1" +tiny-relative-date@^1.3.0: + version "1.3.0" + resolved "https://registry.npmjs.org/tiny-relative-date/-/tiny-relative-date-1.3.0.tgz#fa08aad501ed730f31cc043181d995c39a935e07" + integrity sha512-MOQHpzllWxDCHHaDno30hhLfbouoYlOI8YlMNtvKe1zXbjEVhbcEovQxvZrPvtiYW630GQDoMMarCnjfyfHA+A== + tmp@^0.0.33: version "0.0.33" resolved "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz#6d34335889768d21b2bcda0aa277ced3b1bfadf9" @@ -10438,6 +10962,11 @@ treeify@^1.1.0: resolved "https://registry.npmjs.org/treeify/-/treeify-1.1.0.tgz#4e31c6a463accd0943879f30667c4fdaff411bb8" integrity sha512-1m4RA7xVAJrSGrrXGs0L3YTwyvBs2S8PbRHaLZAkFw7JR8oIFwYtysxlBZhYIa7xSyiYJKZ3iGrrk55cGA3i9A== +treeverse@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/treeverse/-/treeverse-2.0.0.tgz#036dcef04bc3fd79a9b79a68d4da03e882d8a9ca" + integrity sha512-N5gJCkLu1aXccpOTtqV6ddSEi6ZmGkh3hjmbu1IjcavJK4qyOVQmi0myQKM7z5jVGmD68SJoliaVrMmVObhj6A== + trim-newlines@^3.0.0: version "3.0.1" resolved "https://registry.npmjs.org/trim-newlines/-/trim-newlines-3.0.1.tgz#260a5d962d8b752425b32f3a7db0dcacd176c144" @@ -10800,7 +11329,7 @@ url@0.10.3: punycode "1.3.2" querystring "0.2.0" -util-deprecate@^1.0.1, util-deprecate@~1.0.1: +util-deprecate@^1.0.1, util-deprecate@^1.0.2, util-deprecate@~1.0.1: version "1.0.2" resolved "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" integrity sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw== @@ -10920,6 +11449,11 @@ w3c-xmlserializer@^2.0.0: dependencies: xml-name-validator "^3.0.0" +walk-up-path@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/walk-up-path/-/walk-up-path-1.0.0.tgz#d4745e893dd5fd0dbb58dd0a4c6a33d9c9fec53e" + integrity sha512-hwj/qMDUEjCU5h0xr90KGCf0tg0/LgJbmOWgrWKYlcJZM7XvquvUJZ0G/HMGr7F7OQMOUuPHWP9JpriinkAlkg== + walkdir@^0.4.1: version "0.4.1" resolved "https://registry.npmjs.org/walkdir/-/walkdir-0.4.1.tgz#dc119f83f4421df52e3061e514228a2db20afa39" @@ -11096,6 +11630,14 @@ write-file-atomic@^3.0.0, write-file-atomic@^3.0.3: signal-exit "^3.0.2" typedarray-to-buffer "^3.1.5" +write-file-atomic@^4.0.0, write-file-atomic@^4.0.1: + version "4.0.2" + resolved "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-4.0.2.tgz#a9df01ae5b77858a027fd2e80768ee433555fcfd" + integrity sha512-7KxauUdBmSdWnmpaGFg+ppNjKF8uNLry8LyzjauQDOVONfFLNKrKvQOxZ/VuTIcS/gge/YNahf5RIIQWTSarlg== + dependencies: + imurmurhash "^0.1.4" + signal-exit "^3.0.7" + write-json-file@^3.2.0: version "3.2.0" resolved "https://registry.npmjs.org/write-json-file/-/write-json-file-3.2.0.tgz#65bbdc9ecd8a1458e15952770ccbadfcff5fe62a" @@ -11258,7 +11800,7 @@ yargs-parser@^18.1.2: camelcase "^5.0.0" decamelize "^1.2.0" -yargs-parser@^21.1.1: +yargs-parser@^21.0.0, yargs-parser@^21.1.1: version "21.1.1" resolved "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz#9096bceebf990d21bb31fa9516e0ede294a77d35" integrity sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw== @@ -11306,6 +11848,19 @@ yargs@^17.1.1, yargs@^17.6.2: y18n "^5.0.5" yargs-parser "^21.1.1" +yargs@^17.5.0: + version "17.6.0" + resolved "https://registry.npmjs.org/yargs/-/yargs-17.6.0.tgz#e134900fc1f218bc230192bdec06a0a5f973e46c" + integrity sha512-8H/wTDqlSwoSnScvV2N/JHfLWOKuh5MVla9hqLjK3nsfyy6Y4kDSYSvkU5YCUEPOSnRXfIyx3Sq+B/IWudTo4g== + dependencies: + cliui "^8.0.1" + escalade "^3.1.1" + get-caller-file "^2.0.5" + require-directory "^2.1.1" + string-width "^4.2.3" + y18n "^5.0.5" + yargs-parser "^21.0.0" + yn@3.1.1: version "3.1.1" resolved "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz#1e87401a09d767c1d5eab26a6e4c185182d2eb50"