Open traysonkelii opened 7 months ago
I was not able to deploy with the provided code snippets. Are you able to simplify it and provide all necessary info including the buildspec of codebuild and a sample source repo so we can simply run in our local environment and see what's happening?
Here is the buildspec, I will need to work on the sample source repo:
version: 0.2
phases:
install:
commands:
- npm install -g npm
- npm install
build:
commands:
- npm run clean
- npm run build
- npm run cdk -- synth
artifacts:
base-directory: cdk.out
files:
- "**/*"
Here is the actual github repo (it should be public: https://github.com/traysonkelii/combat-sports-ranking-cdk) I'll work on making it smaller.
+1 and bump , Also facing same issue
Describe the issue
I have a few stacks (ServiceStack,AuthenticationStack, and DataStorageStack). All of which work when deployed locally from the CLI. I decided to try and create a simple CICD pipeline using the
Pipeline
construct from theaws-cdk-lib/aws-codepipeline
module. A simple github source to main, along with a simple build step (npm ci, cdk synth). I then use thecdk.out
generated in an artifact to performactions
specifically theCloudFormationCreateUpdateStackAction
on the stacks (essentially update them). Below is the code for thePipelineStack
:The
Authorization_Update
stage fails with the error:Resource handler returned message: "Error occurred while GetObject. S3 Error Code: NoSuchKey. S3 Error Message: The specified key does not exist. (Service: Lambda, Status Code: 400)"
I did check the S3 bucket and the
asset.zip
file found in the template was there. I don't know if there is any other steps I need to do on my part.I checked the documentation and couldn't find anywhere that suggested whether I should enabled any pipeline service principles access to the lambdas or if there were other parameters (
selfMutating
doesn't seem to be an option in this v2 version of code pipelines). I may be lost a little as to what this entails.I've looked through codepipeline module and the CloudFormationCreateUpdateStackAction which seemed extra lean. Any guidance is appreciated.
Links