![](/img/trans.png)
[英]cdk python not fetching value from SSM parameter store even during Deploy Time
[英]CDK deploy not recognizing my bootstrap and SSM parameter
我有一個使用 CDK 的項目,但 CDK Deploy 不起作用。 我的項目是一個簡單的 CDK 應用程序,它已使用cdk init app --language typescript
並且最初可以正常工作。 在這個項目中,我只有一個 lambda 和一個 api 網關。
從@aws-cdk/aws-lambda-nodejs
添加NodejsFunction
后,我遇到了一些錯誤,但是通過在本地安裝 docker 和一些更改,所有這些都得到了解決, synth
現在成功完成。
我運行cdk bootstrap
,然后運行cdk synth
,然后運行cdk deploy
,最后一個是我看到的錯誤:(rest 成功完成)
SSM parameter /cdk-bootstrap/pipeline/version not found. Has the environment been bootstrapped? Please run 'cdk bootstrap' (see https://docs.aws.amazon.com/cdk/latest/guide/bootstrapping.html)
bootstrap 和 synth 工作正常,我的aws configure
已經完成,任何地方都沒有錯誤,但部署不起作用。
更多詳細信息:錯誤:
MyStackNameStack failed: Error: MyStackNameStack: SSM parameter /cdk-bootstrap/pipeline/version not found. Has the environment been bootstrapped? Please run 'cdk bootstrap' (see https://docs.aws.amazon.com/cdk/latest/guide/bootstrapping.html)
at CloudFormationDeployments.validateBootstrapStackVersion (/usr/local/lib/node_modules/aws-cdk/lib/api/cloudformation-deployments.ts:297:13)
at processTicksAndRejections (internal/process/task_queues.js:93:5)
at CloudFormationDeployments.publishStackAssets (/usr/local/lib/node_modules/aws-cdk/lib/api/cloudformation-deployments.ts:272:7)
at CloudFormationDeployments.deployStack (/usr/local/lib/node_modules/aws-cdk/lib/api/cloudformation-deployments.ts:179:5)
at CdkToolkit.deploy (/usr/local/lib/node_modules/aws-cdk/lib/cdk-toolkit.ts:184:24)
at initCommandLine (/usr/local/lib/node_modules/aws-cdk/bin/cdk.ts:213:9)
MyStackNameStack: SSM parameter /cdk-bootstrap/pipeline/version not found. Has the environment been bootstrapped? Please run 'cdk bootstrap' (see https://docs.aws.amazon.com/cdk/latest/guide/bootstrapping.html)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Package.json 和 CLI 版本:
CDK version: 1.116.0
"@aws-cdk/aws-apigateway": "^1.116.0",
"@aws-cdk/aws-lambda": "^1.116.0",
"@aws-cdk/aws-lambda-nodejs": "^1.116.0",
"@aws-cdk/core": "^1.116.0",
我只用這個:
cdk bootstrap
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.