Hi there,
we are using the latest Serverless Container Framework and have set the AWS region to ap-northeast-1, trying to apply a custom domain configuration to the endpoints:
deployment:
type: aws@1.0
containers:
web:
compute:
type: awsLambda
src: .
routing:
domain: our.custom.domain.example.com
pathPattern: /*
pathHealthCheck: /health
However, the framework always fails to attach the appropriate ACM certificate to the CloudFront distribution, with the following error:
InvalidViewerCertificate: The specified SSL certificate doesn't exist, isn't in us-east-1 region, isn't valid, or doesn't include a valid certificate chain.
With the same configuration, we are able to deploy the assets without any issues when we change the AWS region to us-east-1.
We confirmed that the framework automatically creates a new ACM certificate in ap-northeast-1 instead of us-east-1.
It appears it is generating the certificate in the configured region (in our case, ap-northeast-1) but is then treating it as if it were in us-east-1, which is causing the problem.
Creating a certificate in us-east-1 in advance did not help.
We would like to know if there is any configuration option or workaround that can avoid this issue.