Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
46 commits
Select commit Hold shift + click to select a range
b8e06b2
new commit for testing
thogue12 Jun 8, 2025
df48f0b
another one
thogue12 Jun 8, 2025
f3da585
lol
thogue12 Jun 8, 2025
816a569
added some files
thogue12 Jun 8, 2025
b002832
another one
thogue12 Jun 8, 2025
85d7376
fully
thogue12 Jun 10, 2025
7d454dc
Create README.md
thogue12 Jun 18, 2025
302d26e
first commit to VPC module
thogue12 Jun 20, 2025
28ae7c2
additional logic
thogue12 Jun 20, 2025
da0d8ee
new readme
thogue12 Jun 20, 2025
77ede99
new readme
thogue12 Jun 20, 2025
2a175b9
new readme
thogue12 Jun 20, 2025
d0b5b82
new readme
thogue12 Jun 20, 2025
8e9ecd6
another one
thogue12 Jun 23, 2025
8ceafc0
newest commit
thogue12 Jun 23, 2025
8e95805
changed the modules
thogue12 Jun 25, 2025
cb13ae2
another one
thogue12 Jun 25, 2025
36f09ba
anothe one
thogue12 Jun 25, 2025
d88c1ca
Ensure .terraform is ignored
thogue12 Jun 25, 2025
517a084
Editing the modules with for_each this will be v1 of the Edits
thogue12 Jun 25, 2025
cd5a066
Editing the module with for_each this will be v1 of the edits
thogue12 Jun 25, 2025
e5f661e
deleted unncessary files
thogue12 Jun 25, 2025
216b2e4
removed more clutter
thogue12 Jun 25, 2025
d39736d
a big win for the VNET module
thogue12 Jun 26, 2025
2ab708b
Removed sensitive info
thogue12 Jun 26, 2025
cd3e06a
version 1 of the vpc peering module using the VPC Module
thogue12 Jun 26, 2025
694a004
a new commit for the route tables
thogue12 Jun 26, 2025
45470e1
another one
thogue12 Jun 27, 2025
709973e
yet another one
thogue12 Jun 27, 2025
159444a
one for the vnet-peering module
thogue12 Jun 27, 2025
2d04cf8
another one
thogue12 Jun 27, 2025
c238f77
another commit for the vnet peering module
thogue12 Jul 1, 2025
9093e22
added some additional unit testing for infrastructure hardening
thogue12 Jul 2, 2025
bad8e7a
another update
thogue12 Jul 2, 2025
bdcd601
commit to main
thogue12 Jul 2, 2025
19c8245
another one
thogue12 Jul 2, 2025
ab8de37
another one for the books
thogue12 Jul 2, 2025
849c5a7
to the main
thogue12 Jul 2, 2025
7941a72
n
thogue12 Jul 2, 2025
28c95a4
to the main
thogue12 Jul 2, 2025
bc4f2fc
mergig into main
thogue12 Jul 2, 2025
040533f
Merge remote-tracking branch 'origin'
thogue12 Jul 2, 2025
5598160
node
thogue12 Jul 2, 2025
3324bda
Remove .DS_Store and add to gitignore
thogue12 Jul 2, 2025
c8bcc38
changes
thogue12 Jul 2, 2025
576e044
another one
thogue12 Jul 2, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified .github/.DS_Store
Binary file not shown.
26 changes: 26 additions & 0 deletions .github/workflows/trivy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,32 @@ permissions:
packages: write

jobs:
<<<<<<< HEAD
=======
trivy:
name: Trivy Vulnerability Scan
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Run Tricy vulnerabiltiy scanner in repo mode
uses: aquasecurity/trivy-action@0.28.0
with:
scan-type: 'fs'
scan-path: '.'
severity: 'CRITICAL'
format: 'sarif'
output: 'trivy-results.sarif'
ignore-unfixed: true

- name: Upload Trivy scan results to GitHub Security tab
uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: 'trivy-results.sarif'
#

>>>>>>> 6963c00 (another one)
iac_scan:
name: iac_scan
runs-on: ubuntu-24.04
Expand Down
101 changes: 101 additions & 0 deletions .github/workflows/unit-testing.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
name: Unit Testing

on:
workflow_dispatch:

permissions:
actions: read
contents: read
security-events: write
####
jobs:
tf-formatting:
name: 'Terraform Formatting'
runs-on: ubuntu-latest
steps:
- name: 'Checkout GitHub Repo'
uses: actions/checkout@v4

- name: 'Set up Terraform'
uses: hashicorp/setup-terraform@v1
with:
terraform_version: 'latest'

- name: 'Terraform init'
run: terraform init

- name: 'Terraform Format'
run: terraform fmt -check

- name: 'Terraform validate'
run: terraform validate

- name: 'TFLint'
run: |
tflint --init
tflint
####
trivy:
name: Trivy Vulnerability Scan
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Run Trivy vulnerability scanner in repo mode
uses: aquasecurity/trivy-action@0.28.0
with:
scan-type: 'fs'
severity: 'CRITICAL'
format: 'sarif'
output: 'trivy-results.sarif'
ignore-unfixed: true
####
- name: Upload Trivy scan results to GitHub Security tab
uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: 'trivy-results.sarif'

iac_scan:
name: IaC Scan
runs-on: ubuntu-24.04
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Run Trivy vulnerability scanner in IaC mode
uses: aquasecurity/trivy-action@0.28.0
with:
scan-type: 'config'
hide-progress: false
format: 'sarif'
output: 'trivy-results.sarif'
exit-code: '1'
severity: 'CRITICAL'

- name: Upload Trivy scan results to GitHub Security tab
uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: 'trivy-results.sarif'

tfsec:
name: 'tfsec'
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: 'Install Tfsec'
uses: aquasecurity/tfsec-sarif-action@21ded20e8ca120cd9d3d6ab04ef746477542a608
with:
sarif_file: tfsec.sarif
#####
checkov:
name: Run Checkov
runs-on: ubuntu-latest
steps:
- name: 'Run Checkov'
uses: bridgecrewio/checkov-action@v12
with:
output_format: cli,sarif
output_file_path: console,results.sarif
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.terraform/
41 changes: 41 additions & 0 deletions Azure-WAN/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# Local .terraform directories
**/.terraform/*

# .tfstate files
*.tfstate
*.tfstate.*

# Crash log files
crash.log
crash.*.log

# Exclude all .tfvars files, which are likely to contain sensitive data, such as
# password, private keys, and other secrets. These should not be part of version
# control as they are data points which are potentially sensitive and subject
# to change depending on the environment.
*.tfvars
*.tfvars.json

# Ignore override files as they are usually used to override resources locally and so
# are not checked in
override.tf
override.tf.json
*_override.tf
*_override.tf.json

# Ignore transient lock info files created by terraform apply
.terraform.tfstate.lock.info

# Include override files you do wish to add to version control using negated pattern
# !example_override.tf

# Include tfplan files to ignore the plan output of command: terraform plan -out=tfplan
# example: *tfplan*

# Ignore CLI configuration files
.terraformrc
terraform.rc
.terraform.lock.hcl

# Ignore the .DS_Store files created by macOS
.DS_Store
46 changes: 46 additions & 0 deletions Documentation
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
#########################################################
# Topics I'm going to explore in this module
#########################################################


### Conditional logic
- Conditionally create VPC
- Based off the bool the subsequent resources associated to the VPC will be created or not
- Create IGW based off of bool
- That IGW should then have logic in a locals variable, that says. "if the vpc bool == true and the public route table == true then create a route to the internet gateway"
- example logic:
locals{
create_route_to_igw = var.create_vpc && var.create_igw && local.create_public_route_table
}
- Create NAT Gateway based off of bool
- That NAT should then have logic in a locals variable, that says. "if the vpc bool == true and the private subnet creation == true then create a route to the NAT gateway"
- example logic:
locals{
create_route_to_nat = var.create_vpc && var.create_igw && local.create_private_route_table
}
### Count
- Couple conditional logic with the Count meta argument
- Based off of the conditions bool will determine how many of the VPCs are created

### Dynamic Resource Allocation
- Based on how many VPCs are created will result in how many Private, Public Subnets are created
- Along with Route tables for Public and Private subs
- Internet Gateway
- NAT Gateway

### Dynamic CIDR Blocks
- Use one of the Terraform functions to create CIDRs for subnets based off of the VPC created.

### Dynamic Resource Creation:
- allow the user to specify how many of a given resource is created
-

### map(string) variables for tags with string interpolation
- Name
- Environment
- example:
variable "tags"{
description = "tags for each resource"
type = map(string)
default = {}
}
Binary file added IAM/.DS_Store
Binary file not shown.
41 changes: 41 additions & 0 deletions IAM/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# Local .terraform directories
**/.terraform/*

# .tfstate files
*.tfstate
*.tfstate.*

# Crash log files
crash.log
crash.*.log

# Exclude all .tfvars files, which are likely to contain sensitive data, such as
# password, private keys, and other secrets. These should not be part of version
# control as they are data points which are potentially sensitive and subject
# to change depending on the environment.
*.tfvars
*.tfvars.json

# Ignore override files as they are usually used to override resources locally and so
# are not checked in
override.tf
override.tf.json
*_override.tf
*_override.tf.json

# Ignore transient lock info files created by terraform apply
.terraform.tfstate.lock.info

# Include override files you do wish to add to version control using negated pattern
# !example_override.tf

# Include tfplan files to ignore the plan output of command: terraform plan -out=tfplan
# example: *tfplan*

# Ignore CLI configuration files
.terraformrc
terraform.rc
.terraform.lock.hcl

# Ignore the .DS_Store files created by macOS
.DS_Store
41 changes: 41 additions & 0 deletions IAM/CloudWatch-Logging/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# Local .terraform directories
**/.terraform/*

# .tfstate files
*.tfstate
*.tfstate.*

# Crash log files
crash.log
crash.*.log

# Exclude all .tfvars files, which are likely to contain sensitive data, such as
# password, private keys, and other secrets. These should not be part of version
# control as they are data points which are potentially sensitive and subject
# to change depending on the environment.
*.tfvars
*.tfvars.json

# Ignore override files as they are usually used to override resources locally and so
# are not checked in
override.tf
override.tf.json
*_override.tf
*_override.tf.json

# Ignore transient lock info files created by terraform apply
.terraform.tfstate.lock.info

# Include override files you do wish to add to version control using negated pattern
# !example_override.tf

# Include tfplan files to ignore the plan output of command: terraform plan -out=tfplan
# example: *tfplan*

# Ignore CLI configuration files
.terraformrc
terraform.rc
.terraform.lock.hcl

# Ignore the .DS_Store files created by macOS
.DS_Store
Empty file added IAM/CloudWatch-Logging/main.tf
Empty file.
Empty file.
Empty file.
41 changes: 41 additions & 0 deletions IAM/SSM-Policy/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# Local .terraform directories
**/.terraform/*

# .tfstate files
*.tfstate
*.tfstate.*

# Crash log files
crash.log
crash.*.log

# Exclude all .tfvars files, which are likely to contain sensitive data, such as
# password, private keys, and other secrets. These should not be part of version
# control as they are data points which are potentially sensitive and subject
# to change depending on the environment.
*.tfvars
*.tfvars.json

# Ignore override files as they are usually used to override resources locally and so
# are not checked in
override.tf
override.tf.json
*_override.tf
*_override.tf.json

# Ignore transient lock info files created by terraform apply
.terraform.tfstate.lock.info

# Include override files you do wish to add to version control using negated pattern
# !example_override.tf

# Include tfplan files to ignore the plan output of command: terraform plan -out=tfplan
# example: *tfplan*

# Ignore CLI configuration files
.terraformrc
terraform.rc
.terraform.lock.hcl

# Ignore the .DS_Store files created by macOS
.DS_Store
Loading
Loading