Home > Enterprise >  Aws quickstart: vpc configuration
Aws quickstart: vpc configuration

Time:06-24

I lack experience with aws vpc and quickstart. I would like to use a quickstart (enter image description here

CodePudding user response:

The quickstart that you linked does not use S3 gateway endpoint. You have to fork it, and modify it to add the S3 endpoint.

CodePudding user response:

Thanks you for your answer but i'm not sure what i need to change. In the template of the quickstart the vpc config point to another template :

    Resources:
      VPCStack:
        Type: AWS::CloudFormation::Stack
        Properties:
          TemplateURL:
            Fn::Sub:
              - https://${S3Bucket}.s3.${S3Region}.${AWS::URLSuffix}/${QSS3KeyPrefix}submodules/quickstart-aws-vpc/templates/aws-vpc.template.yaml
              - S3Region: !If [UsingDefaultBucket, !Ref 'AWS::Region', !Ref QSS3BucketRegion]
                S3Bucket: !If [UsingDefaultBucket, !Sub '${QSS3BucketName}-${AWS::Region}', !Ref QSS3BucketName]
          Parameters:
            AvailabilityZones:
              Fn::Join:
              - ','
              - !Ref AvailabilityZones
            NumberOfAZs: '2'
            PrivateSubnet1ACIDR: !Ref PrivateSubnet1CIDR
            PrivateSubnet2ACIDR: !Ref PrivateSubnet2CIDR
            PublicSubnet1CIDR: !Ref PublicSubnet1CIDR
            PublicSubnet2CIDR: !Ref PublicSubnet2CIDR
            VPCCIDR: !Ref VPCCIDR

In this vpc template there are these lanes :

S3VPCEndpoint:
    Condition: PrivateSubnetsCondition
    Type: AWS::EC2::VPCEndpoint
    Properties:
      PolicyDocument:
        Version: '2012-10-17'
        Statement:
          - Action: '*'
            Effect: Allow
            Resource: '*'
            Principal: '*'
      RouteTableIds:
        - !Ref 'PrivateSubnet1ARouteTable'
        - !Ref 'PrivateSubnet2ARouteTable'
        - !If [PrivateSubnets&3AZCondition, !Ref 'PrivateSubnet3ARouteTable', !Ref 'AWS::NoValue']
        - !If [PrivateSubnets&4AZCondition, !Ref 'PrivateSubnet4ARouteTable', !Ref 'AWS::NoValue']
        - !If [AdditionalPrivateSubnetsCondition, !Ref 'PrivateSubnet1BRouteTable', !Ref 'AWS::NoValue']
        - !If [AdditionalPrivateSubnetsCondition, !Ref 'PrivateSubnet2BRouteTable', !Ref 'AWS::NoValue']
        - !If [AdditionalPrivateSubnets&3AZCondition, !Ref 'PrivateSubnet3BRouteTable', !Ref 'AWS::NoValue']
        - !If [AdditionalPrivateSubnets&4AZCondition, !Ref 'PrivateSubnet4BRouteTable', !Ref 'AWS::NoValue']
      ServiceName: !Sub 'com.amazonaws.${AWS::Region}.s3'
      VpcId: !Ref 'VPC'

So I thought it was using a s3 gateway endpoint but if not I really don't know what to modify.

  • Related