Skip to content

Commit

Permalink
cleaned up deprecated stuff
Browse files Browse the repository at this point in the history
Signed-off-by: Manuel Weber <[email protected]>
  • Loading branch information
mm-weber committed Nov 8, 2024
1 parent bef0756 commit ed5d881
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 141 deletions.
6 changes: 0 additions & 6 deletions aws/ec2-instances/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,20 +30,14 @@ This repository contains Terraform code for provisioning AWS EC2 instances for t
| Debian 11 CIS cnspec | CIS Debian Linux 11 Benchmark - Level 1 with latest cnspec | `create_debian11_cis_cnspec` | [CIS Debian Linux 11 Benchmark - Level 1](https://aws.amazon.com/marketplace/pp?sku=7158qffnkd38liu1mrksgz53n) |
| Debian 12 CIS | CIS Debian Linux 12 Benchmark - Level 1 | `create_debian12_cis` | [CIS Debian Linux 12 Benchmark - Level 1](https://aws.amazon.com/marketplace/pp/prodview-qx5nmpdvckqgc?applicationId=AWSMPContessa&ref_=beagle&sr=0-3) |
| Debian 12 CIS cnspec | CIS Debian Linux 12 Benchmark - Level 1 with latest cnspec | `create_debian12_cis_cnspec` | [CIS Debian Linux 12 Benchmark - Level 1](https://aws.amazon.com/marketplace/pp/prodview-qx5nmpdvckqgc?applicationId=AWSMPContessa&ref_=beagle&sr=0-3) |
| Oracle 7 | Latest Oracle 7 image -> deprecated | `create_oracle7` | |
| Oracle 7 cnspec | Latest Oracle 7 image with latest cnspec -> deprecated | `create_oracle7_cnspec` | |
| Oracle 7 CIS | CIS Oracle Linux 7 Benchmark - Level 1 | `create_oracle7_cis` | [CIS Oracle Linux 7 Benchmark - Level 1](https://aws.amazon.com/marketplace/pp/prodview-pshwm5x5a7wmg?sr=0-24&ref_=beagle&applicationId=AWSMPContessa) |
| Oracle 7 CIS cnspec | CIS Oracle Linux 7 Benchmark - Level 1 with latest cnspec | `create_oracle7_cis_cnspec` | [CIS Oracle Linux 7 Benchmark - Level 1](https://aws.amazon.com/marketplace/pp/prodview-pshwm5x5a7wmg?sr=0-24&ref_=beagle&applicationId=AWSMPContessa) |
| Oracle 8 | Latest Oracle 8 image -> deprecated | `create_oracle8` | |
| Oracle 8 cnspec | Latest Oracle 8 image with latest cnspec -> deprecated | `create_oracle8_cnspec` | |
| Oracle 8 CIS | CIS Oracle Linux 8 Benchmark - Level 1 | `create_oracle8_cis` | [CIS Oracle Linux 8 Benchmark - Level 1](https://aws.amazon.com/marketplace/pp/prodview-qohiqfju7iecs?sr=0-1&ref_=beagle&applicationId=AWSMPContessa) |
| Oracle 8 CIS cnspec | CIS Oracle Linux 8 Benchmark - Level 1 with latest cnspec | `create_oracle8_cis_cnspec` | [CIS Oracle Linux 8 Benchmark - Level 1](https://aws.amazon.com/marketplace/pp/prodview-qohiqfju7iecs?sr=0-1&ref_=beagle&applicationId=AWSMPContessa) |
| Oracle 9 | Latest Oracle 9 image | `create_oracle9` | |
| Oracle 9 cnspec | Latest Oracle 9 image with latest cnspec | `create_oracle9_cnspec` | |
| Oracle 9 CIS | CIS Oracle Linux 9 Benchmark - Level 1 | `create_oracle9_cis` | [CIS Oracle Linux 9 Benchmark - Level 1](https://aws.amazon.com/marketplace/pp/prodview-uvycouobpppp4?sr=0-1&ref_=beagle&applicationId=AWS-EC2-Console) |
| Oracle 9 CIS cnspec | CIS Oracle Linux 9 Benchmark - Level 1 with latest cnspec | `create_oracle9_cis_cnspec` | [CIS Oracle Linux 9 Benchmark - Level 1](https://aws.amazon.com/marketplace/pp/prodview-uvycouobpppp4?sr=0-1&ref_=beagle&applicationId=AWS-EC2-Console) |
| RHEL 7 | Latest Red Hat Enterprise Linux 7 | `create_rhel7` | |
| RHEL 7 cnspec | Latest Red Hat Enterprise Linux 7 with latest cnspec | `create_rhel7_cnspec` |
| RHEL 7 mondoo pass private | Saved image of a manually hardened CIS RHEL7 image (which CIS deleted) | `create_rhel7_pass_private` | |
| RHEL 8 | Latest Red Hat Enterprise Linux 8 | `create_rhel8` | |
| RHEL 8 cnspec | Latest Red Hat Enterprise Linux 8 with latest cnspec | `create_rhel8_cnspec` | |
Expand Down
64 changes: 0 additions & 64 deletions aws/ec2-instances/amis.tf
Original file line number Diff line number Diff line change
Expand Up @@ -115,22 +115,6 @@ data "aws_ami" "rhel9_cis" {
}


#data "aws_ami" "rhel7" {
# most_recent = true
#
# filter {
# name = "name"
# values = ["RHEL_HA-7*_HVM-*"]
# }
#
# filter {
# name = "virtualization-type"
# values = ["hvm"]
# }
#
# owners = ["309956199498"]
#}

data "aws_ami" "rhel7-cis-pass-private" {
most_recent = true

Expand Down Expand Up @@ -464,54 +448,6 @@ data "aws_ami" "suse15_cis" {
owners = ["679593333241"]
}

#data "aws_ami" "oracle7" {
# most_recent = true
#
# filter {
# name = "name"
# values = ["*SupportedImages OL7.9*"]
# }
#
# filter {
# name = "virtualization-type"
# values = ["hvm"]
# }
#
# owners = ["679593333241"]
#}

#data "aws_ami" "oracle7_cis" {
# most_recent = true
#
# filter {
# name = "name"
# values = ["CIS Oracle Linux 7 Benchmark*"]
# }
#
# filter {
# name = "virtualization-type"
# values = ["hvm"]
# }
#
# owners = ["679593333241"]
#}

#data "aws_ami" "oracle8" {
# most_recent = true
#
# filter {
# name = "name"
# values = ["*SupportedImages OL8.8*"]
# }
#
# filter {
# name = "virtualization-type"
# values = ["hvm"]
# }
#
# owners = ["679593333241"]
#}

data "aws_ami" "oracle8_cis" {
most_recent = true

Expand Down
39 changes: 1 addition & 38 deletions aws/ec2-instances/outputs.tf
Original file line number Diff line number Diff line change
Expand Up @@ -41,20 +41,11 @@ output "centos7_hardened_community" {
value = module.centos7_hardened_community.public_ip == null ? "" : "ssh -o StrictHostKeyChecking=no -i ~/.ssh/${var.aws_key_pair_name} ec2-user@${module.centos7_hardened_community.public_ip}"
}

# rhel 7
#output "rhel7" {
# value = module.rhel7.public_ip == null ? "" : "ssh -o StrictHostKeyChecking=no -i ~/.ssh/${var.aws_key_pair_name} ec2-user@${module.rhel7.public_ip}"
#}
#
# rhel 7 private mondoo image
output "rhel7_pass_private" {
value = module.rhel7_pass_private.public_ip == null ? "" : "ssh -o StrictHostKeyChecking=no -i ~/.ssh/${var.aws_key_pair_name} ec2-user@${module.rhel7_pass_private.public_ip}"
}

#output "rhel7_cnspec" {
# value = module.rhel7_cnspec.public_ip == null ? "" : "ssh -o StrictHostKeyChecking=no -i ~/.ssh/${var.aws_key_pair_name} ec2-user@${module.rhel7_cnspec.public_ip}"
#}
#

# rhel8
output "rhel8" {
value = module.rhel8.public_ip == null ? "" : "ssh -o StrictHostKeyChecking=no -i ~/.ssh/${var.aws_key_pair_name} ec2-user@${module.rhel8.public_ip}"
Expand Down Expand Up @@ -203,34 +194,6 @@ output "suse15_cis_cnspec" {
value = module.suse15_cis_cnspec.public_ip == null ? "" : "ssh -o StrictHostKeyChecking=no -i ~/.ssh/${var.aws_key_pair_name} ec2-user@${module.suse15_cis_cnspec.public_ip}"
}

# oracle7
# oracle7
#output "oracle7" {
# value = module.oracle7.public_ip == null ? "" : "ssh -o StrictHostKeyChecking=no -i ~/.ssh/${var.aws_key_pair_name} ec2-user@${module.oracle7.public_ip}"
#}
#
#output "oracle7_cnspec" {
# value = module.oracle7_cnspec.public_ip == null ? "" : "ssh -o StrictHostKeyChecking=no -i ~/.ssh/${var.aws_key_pair_name} ec2-user@${module.oracle7_cnspec.public_ip}"
#}
#
#output "oracle7_cis" {
# value = module.oracle7_cis.public_ip == null ? "" : "ssh -o StrictHostKeyChecking=no -i ~/.ssh/${var.aws_key_pair_name} ec2-user@${module.oracle7_cis.public_ip}"
#}
#
#output "oracle7_cis_cnspec" {
# value = module.oracle7_cis_cnspec.public_ip == null ? "" : "ssh -o StrictHostKeyChecking=no -i ~/.ssh/${var.aws_key_pair_name} ec2-user@${module.oracle7_cis_cnspec.public_ip}"
#}

# oracle8 deprecated
#output "oracle8" {
# value = module.oracle8.public_ip == null ? "" : "ssh -o StrictHostKeyChecking=no -i ~/.ssh/${var.aws_key_pair_name} ec2-user@${module.oracle8.public_ip}"
#}
#
#output "oracle8_cnspec" {
# value = module.oracle8_cnspec.public_ip == null ? "" : "ssh -o StrictHostKeyChecking=no -i ~/.ssh/${var.aws_key_pair_name} ec2-user@${module.oracle8_cnspec.public_ip}"
#}
#

output "oracle8_cis" {
value = module.oracle8_cis.public_ip == null ? "" : "ssh -o StrictHostKeyChecking=no -i ~/.ssh/${var.aws_key_pair_name} ec2-user@${module.oracle8_cis.public_ip}"
}
Expand Down
33 changes: 0 additions & 33 deletions aws/ec2-instances/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -196,18 +196,10 @@ variable "create_centos7_hardened_community" {
default = false
}

#variable "create_rhel7" {
# default = false
#}

variable "create_rhel7_pass_private" {
default = false
}

#variable "create_rhel7_cnspec" {
# default = false
#}

variable "create_rhel7_cis" {
default = false
}
Expand Down Expand Up @@ -284,31 +276,6 @@ variable "create_suse15_cis_cnspec" {
default = false
}

#DEPRECATED 06.11.2024
#variable "create_oracle7" {
# default = false
#}
#
#variable "create_oracle7_cnspec" {
# default = false
#}

#variable "create_oracle7_cis" {
# default = false
#}
#
#variable "create_oracle7_cis_cnspec" {
# default = false
#}

#variable "create_oracle8" {
# default = false
#}
#
#variable "create_oracle8_cnspec" {
# default = false
#}

variable "create_oracle8_cis" {
default = false
}
Expand Down

0 comments on commit ed5d881

Please sign in to comment.