ref/cfn/build_image_prod.yml [14:118]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Type: String

Resources:
  BuildBucket:
    Type: 'AWS::S3::Bucket'
    DeletionPolicy: Retain

  BuildSStateCacheFilesystem:
    Type: AWS::EFS::FileSystem
    Properties: 
      BackupPolicy: 
        Status: ENABLED
      Encrypted: False
      FileSystemTags: 
        - Key: Name
          Value: !Join
            - ''
            - - !Ref AWS::StackName
              - "/"
              - sstate-cache
      LifecyclePolicies: 
        - TransitionToIA: AFTER_30_DAYS
      PerformanceMode: generalPurpose
      ThroughputMode: bursting

  BuildSStateCacheMountTarget1:
    Type: AWS::EFS::MountTarget
    Properties: 
      FileSystemId: !Ref BuildSStateCacheFilesystem
      SubnetId:
        Fn::ImportValue:
          !Sub "${NetworkStackName}-PrivateSubnet1"
      SecurityGroups:
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-NoIngressSecurityGroup"
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-DefaultSecurityGroup"

  BuildSStateCacheMountTarget2:
    Type: AWS::EFS::MountTarget
    Properties: 
      FileSystemId: !Ref BuildSStateCacheFilesystem
      SubnetId:
        Fn::ImportValue:
          !Sub "${NetworkStackName}-PrivateSubnet2"
      SecurityGroups:
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-NoIngressSecurityGroup"
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-DefaultSecurityGroup"

  BuildDownloadFilesystem:
    Type: AWS::EFS::FileSystem
    Properties: 
      BackupPolicy: 
        Status: ENABLED
      Encrypted: False
      FileSystemTags: 
        - Key: Name
          Value: !Join
            - ''
            - - !Ref AWS::StackName
              - "/"
              - download
      LifecyclePolicies: 
        - TransitionToIA: AFTER_30_DAYS
      PerformanceMode: generalPurpose
      ThroughputMode: bursting


  BuildDownloadMountTarget1:
    Type: AWS::EFS::MountTarget
    Properties: 
      FileSystemId: !Ref BuildDownloadFilesystem
      SubnetId:
        Fn::ImportValue:
          !Sub "${NetworkStackName}-PrivateSubnet1"
      SecurityGroups:
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-NoIngressSecurityGroup"
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-DefaultSecurityGroup"

  BuildDownloadMountTarget2:
    Type: AWS::EFS::MountTarget
    Properties: 
      FileSystemId: !Ref BuildDownloadFilesystem
      SubnetId:
        Fn::ImportValue:
          !Sub "${NetworkStackName}-PrivateSubnet2"
      SecurityGroups:
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-NoIngressSecurityGroup"
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-DefaultSecurityGroup"
    
  CodeBuildProject:
    Type: AWS::CodeBuild::Project
    Properties:
      Artifacts:
        Location: !Ref BuildBucket
        Packaging: NONE
        NamespaceType: BUILD_ID
        Type: S3
      BadgeEnabled: true
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



ref/cfn/build_image_sdk.yml [14:118]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Type: String

Resources:
  BuildBucket:
    Type: 'AWS::S3::Bucket'
    DeletionPolicy: Retain

  BuildSStateCacheFilesystem:
    Type: AWS::EFS::FileSystem
    Properties: 
      BackupPolicy: 
        Status: ENABLED
      Encrypted: False
      FileSystemTags: 
        - Key: Name
          Value: !Join
            - ''
            - - !Ref AWS::StackName
              - "/"
              - sstate-cache
      LifecyclePolicies: 
        - TransitionToIA: AFTER_30_DAYS
      PerformanceMode: generalPurpose
      ThroughputMode: bursting

  BuildSStateCacheMountTarget1:
    Type: AWS::EFS::MountTarget
    Properties: 
      FileSystemId: !Ref BuildSStateCacheFilesystem
      SubnetId:
        Fn::ImportValue:
          !Sub "${NetworkStackName}-PrivateSubnet1"
      SecurityGroups:
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-NoIngressSecurityGroup"
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-DefaultSecurityGroup"

  BuildSStateCacheMountTarget2:
    Type: AWS::EFS::MountTarget
    Properties: 
      FileSystemId: !Ref BuildSStateCacheFilesystem
      SubnetId:
        Fn::ImportValue:
          !Sub "${NetworkStackName}-PrivateSubnet2"
      SecurityGroups:
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-NoIngressSecurityGroup"
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-DefaultSecurityGroup"

  BuildDownloadFilesystem:
    Type: AWS::EFS::FileSystem
    Properties: 
      BackupPolicy: 
        Status: ENABLED
      Encrypted: False
      FileSystemTags: 
        - Key: Name
          Value: !Join
            - ''
            - - !Ref AWS::StackName
              - "/"
              - download
      LifecyclePolicies: 
        - TransitionToIA: AFTER_30_DAYS
      PerformanceMode: generalPurpose
      ThroughputMode: bursting


  BuildDownloadMountTarget1:
    Type: AWS::EFS::MountTarget
    Properties: 
      FileSystemId: !Ref BuildDownloadFilesystem
      SubnetId:
        Fn::ImportValue:
          !Sub "${NetworkStackName}-PrivateSubnet1"
      SecurityGroups:
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-NoIngressSecurityGroup"
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-DefaultSecurityGroup"

  BuildDownloadMountTarget2:
    Type: AWS::EFS::MountTarget
    Properties: 
      FileSystemId: !Ref BuildDownloadFilesystem
      SubnetId:
        Fn::ImportValue:
          !Sub "${NetworkStackName}-PrivateSubnet2"
      SecurityGroups:
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-NoIngressSecurityGroup"
        - Fn::ImportValue:
            !Sub "${NetworkStackName}-DefaultSecurityGroup"
    
  CodeBuildProject:
    Type: AWS::CodeBuild::Project
    Properties:
      Artifacts:
        Location: !Ref BuildBucket
        Packaging: NONE
        NamespaceType: BUILD_ID
        Type: S3
      BadgeEnabled: true
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



