<commit_before>---
AWSTemplateFormatVersion: '2010-09-09'
Description: AWS CloudFormation Template for cross-stack core networking; VPC, DB, private and public subnets
Parameters:
  VPCCidrBlock:
    Type: String
    Description: CidrBlock of new VPC to be created
    Default: 172.30.0.0/20
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
  DBCidrBlock1:
    Type: String
    Description: CidrBlock of new DB Subnet to be created inside VPC
    Default: 172.30.1.0/24
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
  DBCidrBlock2:
    Type: String
    Description: CidrBlock of new DB Subnet to be created inside VPC
    Default: 172.30.2.0/24
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
  DBCidrBlock3:
    Type: String
    Description: CidrBlock of new DB Subnet to be created inside VPC
    Default: 172.30.3.0/24
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
  PrivateCidrBlock1:
    Type: String
    Description: CidrBlock of WebServer Subnet to be created inside VPC
    Default: 172.30.4.0/24
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
  PrivateCidrBlock2:
    Type: String
    Description: CidrBlock of WebServer Subnet to be created inside VPC
    Default: 172.30.5.0/24
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
  PrivateCidrBlock3:
    Type: String
    Description: CidrBlock of WebServer Subnet to be created inside VPC
    Default: 172.30.6.0/24
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
  PublicCidrBlock1:
    Type: String
    Description: CidrBlock of Public Subnet to be created inside VPC
    Default: 172.30.7.0/24
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
  PublicCidrBlock2:
    Type: String
    Description: CidrBlock of Public Subnet to be created inside VPC
    Default: 172.30.8.0/24
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
  PublicCidrBlock3:
    Type: String
    Description: CidrBlock of Public Subnet to be created inside VPC
    Default: 172.30.9.0/24
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
  NATServerAccessCidrBlock1:
    Type: String
    Description: CidrBlock of access to NAT instance outside of VPC
    Default: 0.0.0.0/0
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
  KeyName:
    Description: Name of an existing EC2 KeyPair to enable SSH access to the instances
    Type: AWS::EC2::KeyPair::KeyName
    ConstraintDescription: must be the name of an existing EC2 KeyPair.
  VPNOrganisationName:
    Description: Name of the Organisation
    Type: String
    Default: Virtuability
  VPNOrganisationEmail:
    Description: Email of the Organisation
    Type: String
    Default: <EMAIL>
  VPNCidrBlock:
    Type: String
    Description: CidrBlock of VPN server (.1) and clients
    Default: 10.254.0.0 255.255.255.0
  VPNRouteToAWS:
    Type: String
    Description: VPN route to AWS (pushed to client)
    Default: 172.30.0.0 255.255.240.0
  VPNRouteToVPN:
    Type: String
    Description: VPN route to AWS (pushed to client)
    Default: 10.254.0.0/24
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
  AZNumber:
    Type: Number
    Description: Number of AZs required. Currently only 2 and 3 permitted.<commit_msg>add min and max param constraints.<commit_after>---
AWSTemplateFormatVersion: '2010-09-09'
Description: AWS CloudFormation Template for cross-stack core networking; VPC, DB, private and public subnets
Parameters:
  VPCCidrBlock:
    Type: String
    Description: CidrBlock of new VPC to be created
    Default: 172.30.0.0/20
    MinLength: 9
    MaxLength: 18
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
    ConstraintDescription: Must be a valid CIDR range in the form x.x.x.x/20
  DBCidrBlock1:
    Type: String
    Description: CidrBlock of new DB Subnet to be created inside VPC
    Default: 172.30.1.0/24
    MinLength: 9
    MaxLength: 18
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
    ConstraintDescription: Must be a valid CIDR range in the form x.x.x.x/24
  DBCidrBlock2:
    Type: String
    Description: CidrBlock of new DB Subnet to be created inside VPC
    Default: 172.30.2.0/24
    MinLength: 9
    MaxLength: 18
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
    ConstraintDescription: Must be a valid CIDR range in the form x.x.x.x/24
  DBCidrBlock3:
    Type: String
    Description: CidrBlock of new DB Subnet to be created inside VPC
    Default: 172.30.3.0/24
    MinLength: 9
    MaxLength: 18
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
    ConstraintDescription: Must be a valid CIDR range in the form x.x.x.x/24
  PrivateCidrBlock1:
    Type: String
    Description: CidrBlock of WebServer Subnet to be created inside VPC
    Default: 172.30.4.0/24
    MinLength: 9
    MaxLength: 18
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
    ConstraintDescription: Must be a valid CIDR range in the form x.x.x.x/24
  PrivateCidrBlock2:
    Type: String
    Description: CidrBlock of WebServer Subnet to be created inside VPC
    Default: 172.30.5.0/24
    MinLength: 9
    MaxLength: 18
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
    ConstraintDescription: Must be a valid CIDR range in the form x.x.x.x/24
  PrivateCidrBlock3:
    Type: String
    Description: CidrBlock of WebServer Subnet to be created inside VPC
    Default: 172.30.6.0/24
    MinLength: 9
    MaxLength: 18
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
    ConstraintDescription: Must be a valid CIDR range in the form x.x.x.x/24
  PublicCidrBlock1:
    Type: String
    Description: CidrBlock of Public Subnet to be created inside VPC
    Default: 172.30.7.0/24
    MinLength: 9
    MaxLength: 18
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
    ConstraintDescription: Must be a valid CIDR range in the form x.x.x.x/24
  PublicCidrBlock2:
    Type: String
    Description: CidrBlock of Public Subnet to be created inside VPC
    Default: 172.30.8.0/24
    MinLength: 9
    MaxLength: 18
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
    ConstraintDescription: Must be a valid CIDR range in the form x.x.x.x/24
  PublicCidrBlock3:
    Type: String
    Description: CidrBlock of Public Subnet to be created inside VPC
    Default: 172.30.9.0/24
    MinLength: 9
    MaxLength: 18
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
    ConstraintDescription: Must be a valid CIDR range in the form x.x.x.x/24
  NATServerAccessCidrBlock1:
    Type: String
    Description: CidrBlock of access to NAT instance outside of VPC
    Default: 0.0.0.0/0
    MinLength: 9
    MaxLength: 18
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
    ConstraintDescription: Must be a valid CIDR range in the form x.x.x.x/0
  KeyName:
    Description: Name of an existing EC2 KeyPair to enable SSH access to the instances
    Type: AWS::EC2::KeyPair::KeyName
    ConstraintDescription: must be the name of an existing EC2 KeyPair.
  VPNOrganisationName:
    Description: Name of the Organisation
    Type: String
    Default: Virtuability
  VPNOrganisationEmail:
    Description: Email of the Organisation
    Type: String
    Default: <EMAIL>
  VPNCidrBlock:
    Type: String
    Description: CidrBlock of VPN server (.1) and clients
    Default: 10.254.0.0 255.255.255.0
  VPNRouteToAWS:
    Type: String
    Description: VPN route to AWS (pushed to client)
    Default: 172.30.0.0 255.255.240.0
  VPNRouteToVPN:
    Type: String
    Description: VPN route to AWS (pushed to client)
    Default: 10.254.0.0/24
    MinLength: 9
    MaxLength: 18
    AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
    ConstraintDescription: Must be a valid CIDR range in the form x.x.x.x/24
  AZNumber:
    Type: Number
    Description: Number of AZs required. Currently only 2 and 3 permitted.
{'fraction_non_alphanumeric': 0.24699270360875566, 'fraction_numerical': 0.15135081837901795, 'mean_word_length': 3.494018608772707, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 32, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5288880', 'n_tokens_mistral': 5278, 'n_tokens_neox': 4974, 'n_words': 804}