From 550c741099502a15f555ee2c2fabefab69f7969e Mon Sep 17 00:00:00 2001 From: davmayd Date: Mon, 18 Jul 2022 15:03:33 -0500 Subject: [PATCH] Linting remediation --- templates/ad-1.template.yaml | 1 + templates/ad-3.template.yaml | 7 +----- templates/ad-main-1.template.yaml | 2 ++ templates/ad-main-2.template.yaml | 2 ++ templates/ad-main-3.template.yaml | 2 ++ templates/ad-master-1.template | 2 ++ templates/ad-master-2.template | 2 ++ templates/ad-master-3.template | 2 ++ templates/mgmt-1.template.yaml | 38 +++++++++++++++++++------------ 9 files changed, 38 insertions(+), 20 deletions(-) diff --git a/templates/ad-1.template.yaml b/templates/ad-1.template.yaml index a83decd..fb6008b 100644 --- a/templates/ad-1.template.yaml +++ b/templates/ad-1.template.yaml @@ -11,6 +11,7 @@ Metadata: ignore_checks: - W9006 - E9101 + - W9901 QuickStartDocumentation: EntrypointName: Parameters for deploying self-managed AD into an existing VPC Order: '2' diff --git a/templates/ad-3.template.yaml b/templates/ad-3.template.yaml index 4023db3..2937877 100644 --- a/templates/ad-3.template.yaml +++ b/templates/ad-3.template.yaml @@ -10,6 +10,7 @@ Metadata: ignore_checks: - W9006 - E9101 + - W9901 QuickStartDocumentation: EntrypointName: Parameters for deploying AWS Managed Microsoft AD into an existing VPC Order: '6' @@ -357,12 +358,6 @@ Conditions: ShouldCreateTwoTierPkiResource: !Equals [!Ref PKI, 'Two-Tier'] UsingDefaultBucket: !Equals [!Ref QSS3BucketName, 'aws-quickstart'] Resources: - Windows2022AMISMParameter: - Type: AWS::SSM::Parameter - Properties: - Type: String - Value: !FindInMap [ AWSAMIRegionMap, !Ref "AWS::Region", WIN2022 ] - Description: Windows Server 2022 AMI ID from AWSAMIRegionMap DHCPOptions: Condition: ShouldCreateDHCPOption Type: AWS::EC2::DHCPOptions diff --git a/templates/ad-main-1.template.yaml b/templates/ad-main-1.template.yaml index 8f65a8f..2f58d05 100644 --- a/templates/ad-main-1.template.yaml +++ b/templates/ad-main-1.template.yaml @@ -11,6 +11,8 @@ Metadata: config: ignore_checks: - W9006 + - W9901 + - E9902 QuickStartDocumentation: EntrypointName: Parameters for deploying self-managed AD into a new VPC Order: '1' diff --git a/templates/ad-main-2.template.yaml b/templates/ad-main-2.template.yaml index 2a578cb..51cf986 100644 --- a/templates/ad-main-2.template.yaml +++ b/templates/ad-main-2.template.yaml @@ -10,6 +10,8 @@ Metadata: config: ignore_checks: - W9006 + - W9901 + - E9902 QuickStartDocumentation: EntrypointName: Parameters for extending on-premises AD into a new VPC Order: '3' diff --git a/templates/ad-main-3.template.yaml b/templates/ad-main-3.template.yaml index 77b69c2..47e7d0e 100644 --- a/templates/ad-main-3.template.yaml +++ b/templates/ad-main-3.template.yaml @@ -11,6 +11,8 @@ Metadata: config: ignore_checks: - W9006 + - W9901 + - E9902 QuickStartDocumentation: EntrypointName: Parameters for deploying AWS Managed Microsoft AD into a new VPC Order: '5' diff --git a/templates/ad-master-1.template b/templates/ad-master-1.template index 8f65a8f..2f58d05 100644 --- a/templates/ad-master-1.template +++ b/templates/ad-master-1.template @@ -11,6 +11,8 @@ Metadata: config: ignore_checks: - W9006 + - W9901 + - E9902 QuickStartDocumentation: EntrypointName: Parameters for deploying self-managed AD into a new VPC Order: '1' diff --git a/templates/ad-master-2.template b/templates/ad-master-2.template index 2a578cb..51cf986 100644 --- a/templates/ad-master-2.template +++ b/templates/ad-master-2.template @@ -10,6 +10,8 @@ Metadata: config: ignore_checks: - W9006 + - W9901 + - E9902 QuickStartDocumentation: EntrypointName: Parameters for extending on-premises AD into a new VPC Order: '3' diff --git a/templates/ad-master-3.template b/templates/ad-master-3.template index 77b69c2..47e7d0e 100644 --- a/templates/ad-master-3.template +++ b/templates/ad-master-3.template @@ -11,6 +11,8 @@ Metadata: config: ignore_checks: - W9006 + - W9901 + - E9902 QuickStartDocumentation: EntrypointName: Parameters for deploying AWS Managed Microsoft AD into a new VPC Order: '5' diff --git a/templates/mgmt-1.template.yaml b/templates/mgmt-1.template.yaml index ffb9bfc..562d5ea 100644 --- a/templates/mgmt-1.template.yaml +++ b/templates/mgmt-1.template.yaml @@ -3,13 +3,22 @@ Description: >- This template creates 1 Windows Server Managment Instance in a private subnet inside a VPC. **WARNING** This template creates an Amazon EC2 Windows instance and related resources. You will be billed for the AWS resources used if you create a stack from this template. (qs-1rteoo9fs) Metadata: + cfn-lint: + config: + ignore_checks: + - W9006 + - W9901 + - E9902 + - W9002 + - E9101 + - W9003 AWS::CloudFormation::Interface: ParameterGroups: - Label: default: Network Configuration Parameters: - VPCCIDR - - VPCID +# - VPCID - MgmtServerSubnet - DomainMembersSG - Label: @@ -76,8 +85,8 @@ Metadata: default: Quick Start S3 Key Prefix VPCCIDR: default: VPC CIDR - VPCID: - default: VPC ID +# VPCID: +# default: VPC ID Parameters: AdministratorSecret: Description: ARN for the Administrator credentials Secret @@ -125,6 +134,7 @@ Parameters: MgmtAmi: Default: /aws/service/ami-windows-latest/Windows_Server-2022-English-Full-Base Type: AWS::SSM::Parameter::Value + Description: AMI to use for the management instance MgmtDataDriveSizeGiB: Default: '2' Description: Size of the data drive in GiB @@ -186,18 +196,18 @@ Parameters: Default: 10.0.0.0/16 Description: CIDR Block for the VPC Type: String - VPCID: - Description: ID of the VPC (e.g., vpc-0343606e) - Type: AWS::EC2::VPC::Id +# VPCID: +# Description: ID of the VPC (e.g., vpc-0343606e) +# Type: AWS::EC2::VPC::Id Rules: - SubnetsInVPC: - Assertions: - - Assert: !EachMemberIn - - !ValueOfAll - - AWS::EC2::Subnet::Id - - VpcId - - !RefAll 'AWS::EC2::VPC::Id' - AssertDescription: All subnets must in the VPC +# SubnetsInVPC: +# Assertions: +# - Assert: !EachMemberIn +# - !ValueOfAll +# - AWS::EC2::Subnet::Id +# - VpcId +# - !RefAll 'AWS::EC2::VPC::Id' +# AssertDescription: All subnets must in the VPC NonWindowsDomainJoin: RuleCondition: !Equals [!Ref NonWindowsDomainJoin, 'true'] Assertions: