SAM CLI Deployment error creating S3 Bucket

0

I'm trying to deploy the hello world app created with Quarkus following the guide (http://quarkus.io/guides/amazon-lambda-http).

Everything works fine locally (sam local start-api --template target/sam.jvm.yaml).

When I try to deploy to my aws account, I'm getting an error in the console. The command to deploy is: sam deploy -t target/sam.jvm.yaml -g

Error: Failed to create managed resources: Waiter StackCreateComplete failed: Waiter encountered a terminal failure state: For expression "Stacks[].StackStatus" we matched expected path: "ROLLBACK_COMPLETE" at least once

Looking at the AWS CloudFormation console, it looks like the S3 bucket is what is erroring out on creation:

The step is: SamCliSourceBucketBucketPolicy
The error is: Create Failed
Error Details:

The specified bucket is not valid. (Service: Amazon S3; Status Code: 400; Error Code: InvalidBucketName; Request ID: 0Z7AAGBJ59K08QWV; S3 Extended Request ID: TYpczg8AGNGy+ryR7aLanMhNautgYQ2cQC4OujAskOFZyUzBp/y87pjavD1OEUuw0D/GJdiemzk=; Proxy: null)

I've also tried to pre-create the S3 bucket and that didn't work by adding the --s3-bucket flag to the deployment command.

Anyone have any ideas on what to do next to deploy the hello world starter app to aws lambda?

Thanks,
Chris....

demandé il y a 3 ans4730 vues
2 réponses
1

Thank you! That was my issue and upgrading fixed it. Appreciate your reply and marked the answer as correct.

répondu il y a 3 ans
0
Réponse acceptée

Facing the exact same issue with a different sam project. I found this: https://github.com/aws/aws-sam-cli/issues/3243#issuecomment-915676257

If you are on aws-sam-cli 1.30.0, that is most likely the problem.

Edited by: TOKelly on Sep 16, 2021 5:01 AM

TOKelly
répondu il y a 3 ans

Vous n'êtes pas connecté. Se connecter pour publier une réponse.

Une bonne réponse répond clairement à la question, contient des commentaires constructifs et encourage le développement professionnel de la personne qui pose la question.

Instructions pour répondre aux questions