

Die vorliegende Übersetzung wurde maschinell erstellt. Im Falle eines Konflikts oder eines Widerspruchs zwischen dieser übersetzten Fassung und der englischen Fassung (einschließlich infolge von Verzögerungen bei der Übersetzung) ist die englische Fassung maßgeblich.

# Starte eine landing zone mit CloudFormation
<a name="lz-apis-cfn"></a>

Sie können eine landing zone CloudFormation entweder über die CloudFormation Konsole oder über die konfigurieren und starten AWS CLI. Dieser Abschnitt enthält Anweisungen und Beispiele zum Starten einer landing zone mithilfe von APIs Through CloudFormation. 

**Topics**
+ [Voraussetzungen für den Start einer landing zone mit CloudFormation](lz-apis-cfn-setup.md)
+ [Erstellen Sie eine neue landing zone mit CloudFormation](lz-apis-cfn-launch.md)
+ [Verwalte eine bestehende landing zone mit CloudFormation](lz-apis-cfn-launch-existing.md)

# Voraussetzungen für den Start einer landing zone mit CloudFormation
<a name="lz-apis-cfn-setup"></a>

1. Verwenden Sie von der aus die AWS Organizations `CreateOrganization` API AWS CLI, um eine Organisation zu erstellen und alle Funktionen zu aktivieren. 

   Genauere Anweisungen finden Sie unter[Schritt 1: Konfiguriere deine landing zone](lz-api-prereques.md). 

1. Stellen Sie über die CloudFormation Konsole oder mithilfe der AWS CLI eine CloudFormation Vorlage bereit, mit der die folgenden Ressourcen im Verwaltungskonto erstellt werden: 
   + Log Archive-Konto (manchmal auch als „Logging“ -Konto bezeichnet) 
   + Auditkonto (manchmal auch als „Sicherheitskonto“ bezeichnet) 
   + Die Rollen **AWSControlTowerAdmin**AWSControlTowerCloudTrailRole****, **AWSControlTowerConfigAggregatorRoleForOrganizations**, und **AWSControlTowerStackSetRole**Service. 

     Informationen darüber, wie AWS Control Tower diese Rollen verwendet, um Landingzone-API-Aufrufe durchzuführen, finden Sie unter [Schritt 1: Konfiguration Ihrer landing zone](lz-api-prereques.md). 

   ```
   Parameters:
     LoggingAccountEmail:
       Type: String
       Description: The email Id for centralized logging account
     LoggingAccountName:
       Type: String
       Description: Name for centralized logging account
     SecurityAccountEmail:
       Type: String
       Description: The email Id for security roles account
     SecurityAccountName:
       Type: String
       Description: Name for security roles account
   Resources:
     MyOrganization:
       Type: 'AWS::Organizations::Organization'
       Properties:
         FeatureSet: ALL
     LoggingAccount:
       Type: 'AWS::Organizations::Account'
       Properties:
         AccountName: !Ref LoggingAccountName
         Email: !Ref LoggingAccountEmail
     SecurityAccount:
       Type: 'AWS::Organizations::Account'
       Properties:
         AccountName: !Ref SecurityAccountName
         Email: !Ref SecurityAccountEmail
     AWSControlTowerAdmin:
       Type: 'AWS::IAM::Role'
       Properties:
         RoleName: AWSControlTowerAdmin
         AssumeRolePolicyDocument:
           Version: 2012-10-17		 	 	 
           Statement:
             - Effect: Allow
               Principal:
                 Service: controltower.amazonaws.com
               Action: 'sts:AssumeRole'
         Path: '/service-role/'
         ManagedPolicyArns:
           - !Sub >-
             arn:${AWS::Partition}:iam::aws:policy/service-role/AWSControlTowerServiceRolePolicy
     AWSControlTowerAdminPolicy:
       Type: 'AWS::IAM::Policy'
       Properties:
         PolicyName: AWSControlTowerAdminPolicy
         PolicyDocument:
           Version: 2012-10-17		 	 	 
           Statement:
             - Effect: Allow
               Action: 'ec2:DescribeAvailabilityZones'
               Resource: '*'
         Roles:
           - !Ref AWSControlTowerAdmin
     AWSControlTowerCloudTrailRole:
       Type: 'AWS::IAM::Role'
       Properties:
         RoleName: AWSControlTowerCloudTrailRole
         AssumeRolePolicyDocument:
           Version: 2012-10-17		 	 	 
           Statement:
             - Effect: Allow
               Principal:
                 Service: cloudtrail.amazonaws.com
               Action: 'sts:AssumeRole'
         Path: '/service-role/'
     AWSControlTowerCloudTrailRolePolicy:
       Type: 'AWS::IAM::Policy'
       Properties:
         PolicyName: AWSControlTowerCloudTrailRolePolicy
         PolicyDocument:
           Version: 2012-10-17		 	 	 
           Statement:
             - Action:
                 - 'logs:CreateLogStream'
                 - 'logs:PutLogEvents'
               Resource: !Sub >-
                 arn:${AWS::Partition}:logs:*:*:log-group:aws-controltower/CloudTrailLogs:*
               Effect: Allow
         Roles:
           - !Ref AWSControlTowerCloudTrailRole
     AWSControlTowerConfigAggregatorRoleForOrganizations:
       Type: 'AWS::IAM::Role'
       Properties:
         RoleName: AWSControlTowerConfigAggregatorRoleForOrganizations
         AssumeRolePolicyDocument:
           Version: 2012-10-17		 	 	 
           Statement:
             - Effect: Allow
               Principal:
                 Service: config.amazonaws.com
               Action: 'sts:AssumeRole'
         Path: '/service-role/'
         ManagedPolicyArns:
           - !Sub arn:${AWS::Partition}:iam::aws:policy/service-role/AWSConfigRoleForOrganizations
     AWSControlTowerStackSetRole:
       Type: 'AWS::IAM::Role'
       Properties:
         RoleName: AWSControlTowerStackSetRole
         AssumeRolePolicyDocument:
           Version: 2012-10-17		 	 	 
           Statement:
             - Effect: Allow
               Principal:
                 Service: cloudformation.amazonaws.com
               Action: 'sts:AssumeRole'
         Path: '/service-role/'
     AWSControlTowerStackSetRolePolicy:
       Type: 'AWS::IAM::Policy'
       Properties:
         PolicyName: AWSControlTowerStackSetRolePolicy
         PolicyDocument:
           Version: 2012-10-17		 	 	 
           Statement:
             - Action: 'sts:AssumeRole'
               Resource: !Sub 'arn:${AWS::Partition}:iam::*:role/AWSControlTowerExecution'
               Effect: Allow
         Roles:
           - !Ref AWSControlTowerStackSetRole
   
   Outputs:
     LogAccountId:
       Value:
         Fn::GetAtt: LoggingAccount.AccountId
       Export:
         Name: LogAccountId
     SecurityAccountId:
       Value:
         Fn::GetAtt: SecurityAccount.AccountId
       Export:
         Name: SecurityAccountId
   ```

# Erstellen Sie eine neue landing zone mit CloudFormation
<a name="lz-apis-cfn-launch"></a>

Stellen Sie über die CloudFormation Konsole oder mithilfe der die folgende CloudFormation Vorlage bereit AWS CLI, um eine landing zone zu erstellen. 

```
Parameters:
  Version:
    Type: String
    Description: The version number of Landing Zone
  GovernedRegions:
    Type: Array
    Description: List of governed regions
  SecurityOuName:
    Type: String
    Description: The security Organizational Unit name
  SandboxOuName:
    Type: String
    Description: The sandbox Organizational Unit name
  CentralizedLoggingAccountId:
    Type: String
    Description: The AWS account ID for centralized logging
  SecurityAccountId:
    Type: String
    Description: The AWS account ID for security roles
  LoggingBucketRetentionPeriod:
    Type: Number
    Description: Retention period for centralized logging bucket
  AccessLoggingBucketRetentionPeriod:
    Type: Number
    Description: Retention period for access logging bucket
  KMSKey:
    Type: String
    Description: KMS key ARN used by CloudTrail and Config service to encrypt data in logging bucket
Resources:
  MyLandingZone:
    Type: 'AWS::ControlTower::LandingZone'
    Properties:
      Version:
        Ref: Version
      Tags:
        - Key: "keyname1"
          Value: "value1"
        - Key: "keyname2"
          Value: "value2"
      Manifest:
        governedRegions:
          Ref: GovernedRegions
        organizationStructure:
          security:
            name:
              Ref: SecurityOuName
          sandbox:
            name:
              Ref: SandboxOuName
        centralizedLogging:
          accountId:
            Ref: CentralizedLoggingAccountId
          configurations:
            loggingBucket:
              retentionDays:
                Ref: LoggingBucketRetentionPeriod
            accessLoggingBucket:
              retentionDays:
                Ref: AccessLoggingBucketRetentionPeriod
            kmsKeyArn:
              Ref: KMSKey    
          enabled: true
        securityRoles:
          accountId:
            Ref: SecurityAccountId
        accessManagement:
          enabled: true
```

# Verwalte eine bestehende landing zone mit CloudFormation
<a name="lz-apis-cfn-launch-existing"></a>

Sie können CloudFormation damit eine landing zone verwalten, die Sie bereits gestartet haben, indem Sie die landing zone in einen neuen oder vorhandenen CloudFormation Stack importieren. Einzelheiten [und Anweisungen finden Sie unter Einbindung vorhandener Ressourcen in die CloudFormation Verwaltung](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/resource-import.html). 

Um [Abweichungen innerhalb einer landing zone zu erkennen und zu beheben](https://docs.aws.amazon.com/controltower/latest/userguide/drift.html), können Sie die AWS Control Tower Tower-Konsole AWS CLI, die oder die [`ResetLandingZone`API](lz-api-reset.md) verwenden. 