SAM pipeline removed after deploy
See original GitHub issueDescription:
I’m using the hello world template with python 3.8 to test the “sam pipeline bootstrap” feature.
I’m executing sam deploy -t codepipeline.yaml --stack-name sam-desarrollo --capabilities=CAPABILITY_IAM
In order to deploy the pipeline. It fails in my case due the github connection.
After update GitHub connector and retry the pipeline, it start normally but in some point, the pipeline itself is deleted.
Steps to reproduce:
sam init
select python 3.8 and hello world proyect.
sam pipeline init --bootstrap
Select AWS Pipeline as CI/CD, github as git provider.
sam deploy -t codepipeline.yaml --stack-name myStack --capabilities=CAPABILITY_IAM
At this point the pipeline will fail. Update the pending conection for github.
Push the generated pipeline files to git, it will trigger the pipeline.
The pipeline start normally but at some point, is removed.
Observed result:
Cloud trail show a DeletePipeline event.
{
"eventVersion": "1.08",
"userIdentity": {
"type": "AssumedRole",
"principalId": "xxxx:AWSCloudFormation",
"arn": "arn:aws:sts::xxxx:assumed-role/aws-sam-cli-managed-dev-p-CloudFormationExecutionR-5524JO8QQ6S9/AWSCloudFormation",
"accountId": "xxxx",
"invokedBy": "cloudformation.amazonaws.com"
},
"eventTime": "2022-03-16T18:01:26Z",
"eventSource": "codepipeline.amazonaws.com",
"eventName": "DeletePipeline",
"requestParameters": {
"name": "MyStack-Pipeline-11AZSNLODS7NX"
},
}
Expected result:
Keep pipeline, I have no idea why is removed.
Additional environment details (Ex: Windows, Mac, Amazon Linux etc)
SAM CLI, version 1.40.0
Add --debug flag to any SAM CLI commands you are running
Issue Analytics
- State:
- Created 2 years ago
- Comments:11 (2 by maintainers)
Thanks, @dorlanpabon. It’s what you said. Don’t set the same stack name as your SAM application because doing so will overwrite your application’s stack (and delete your application resources).
Compañeros, hay algo que pude evidencia un tiempo, el nombre del stage que se pide en el sam deploy, no puede ser el mismo que los stage creados, pues eso es lo que ocasiona la sobrescritura y eliminación de la pila