We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add-dns-and-certificate-to-apigateway ブランチのお試しコードにて。
add-dns-and-certificate-to-apigateway
CDKにて、本来の用途と思える apigateway.DomainName を使っての「カスタムドメインの作成」したい。
apigateway.DomainName
const certificateArn = StringParameter.valueFromLookup(this, settings.certArnPraStoreName()); const certificate = Certificate.fromCertificateArn(this, 'LookUpCertification', certificateArn); const fqdn = settings.currentStage().apiFqdn; console.log("ドメイン名: " + fqdn); console.log("現在のリージョン:" + this.region); // カスタムドメインの設定 const domainName = new apigateway.DomainName(this, 'domain-name', { domainName: fqdn, certificate: certificate, endpointType: apigateway.EndpointType.REGIONAL, securityPolicy: apigateway.SecurityPolicy.TLS_1_2, });
上記コードにてCDK実行した場合、以下のエラーが発生する。
Invalid request provided: The certificate provided must be owned by the account creating the domain.
また、バグではないが、 endpointType: apigateway.EndpointType.EDGE, に変更した場合は、
endpointType: apigateway.EndpointType.EDGE,
Invalid request provided: Invalid certificate ARN: arn:aws:acm:xxx. ... Certificate must be in 'us-east-1'.
となり、こちらもエラーとなり、結局生成出来ない。(EDGEでは証明書を北米に作らなくてはならない)
類似の事例もあるにはあるが…
見る限りは「違うリージョンに証明書を作ってしまった場合に出るメッセージ」という程度である。
可能性として考えられるのは、
cdk bootstrap
CDKToolkit
だが、後者をやった記憶はないし、前者であれば「2つ以上のStackで制御できない」となり、少し現実味にかける。
未、解決出来ず、ブロック
The text was updated successfully, but these errors were encountered:
No branches or pull requests
現象
add-dns-and-certificate-to-apigateway
ブランチのお試しコードにて。CDKにて、本来の用途と思える
apigateway.DomainName
を使っての「カスタムドメインの作成」したい。上記コードにてCDK実行した場合、以下のエラーが発生する。
また、バグではないが、
endpointType: apigateway.EndpointType.EDGE,
に変更した場合は、となり、こちらもエラーとなり、結局生成出来ない。(EDGEでは証明書を北米に作らなくてはならない)
考察
類似の事例もあるにはあるが…
見る限りは「違うリージョンに証明書を作ってしまった場合に出るメッセージ」という程度である。
可能性として考えられるのは、
cdk bootstrap
を行ってしまい、別のアカウント扱い(CDKToolkit
スタックが別物)だが、後者をやった記憶はないし、前者であれば「2つ以上のStackで制御できない」となり、少し現実味にかける。
解決
未、解決出来ず、ブロック
The text was updated successfully, but these errors were encountered: