rights reserved. コントロールプレーンの設定 import { CognitoAuth, ControlPlane } from '@cdklabs/sbt-aws'; import { Stack } from 'aws-cdk-lib'; import { Construct } from 'constructs'; export class ControlPlaneStack extends Stack { public readonly regApiGatewayUrl: string; public readonly eventBusArn: string; constructor(scope: Construct, id: string, props: any) { super(scope, id, props); const cognitoAuth = new CognitoAuth(this, 'CognitoAuth', { systemAdminRoleName: 'SystemAdmin’, systemAdminEmail: '
[email protected]’, }); const controlPlane = new ControlPlane(this, 'ControlPlane', { auth: cognitoAuth, }); this.eventBusArn = controlPlane.eventManager.busArn; this.regApiGatewayUrl = controlPlane.controlPlaneAPIGatewayUrl; } } ※ IdP として Amazon Cognito を利用。IAuth インターフェースを実装していれば、任意の IdP に差し替え可能 39