chalice
chalice copied to clipboard
Deleting one of the stages having a custom domain, incorrectly deletes the custom domain
Consider the following configuration
{
"version": "2.0",
"app_name": "Hello",
"api_gateway_endpoint_type": "REGIONAL",
"stages": {
"v1": {
"api_gateway_stage": "v1",
"api_gateway_custom_domain": {
"domain_name": "hello.example.com",
"certificate_arn": "arn:aws:acm:xxx",
"url_prefix": "v1"
}
},
"v2": {
"api_gateway_stage": "v2",
"api_gateway_custom_domain": {
"domain_name": "hello.example.com",
"certificate_arn": "arn:aws:acm:xxx",
"url_prefix": "v2"
}
}
}
}
The above configuration is used to create two versions of the API under the same domain, as described in this issue.
Deploy the two versions
chalice deploy --stage v1
chalice deploy --stage v2
Delete v2
chalice delete --stage v2
Deleting custom domain name: api_gateway_custom_domain
This results in deleting the custom domain entirely from API Gateway service, causing issues with all the other existing stages (e.g v1 in the example above)
@tfotis how did you solve that issue? Please help us ;)