From f47f92caa7dff286bd295edde89683ccc688be55 Mon Sep 17 00:00:00 2001
From: Your Name <penenadpi@gmail.com>
Date: Tue, 9 Aug 2022 08:42:26 +0200
Subject: [PATCH] Deleting the temporary files and output examples

---
 examples/database.tf                          | 25 +++++++++++++++++
 examples/main.tf                              |  7 +++++
 .../test => examples}/test_scanner_simple.py  |  0
 src/generated_html/1658820632.92485.html      |  1 -
 src/json_dumps/1658820632.92485.json          |  1 -
 src/scan_run_1658820632.92485/tflint.txt      |  0
 src/scan_run_1658820632.92485/tfsec.txt       | 27 -------------------
 7 files changed, 32 insertions(+), 29 deletions(-)
 create mode 100644 examples/database.tf
 create mode 100644 examples/main.tf
 rename {src/iac_scan_runner/test => examples}/test_scanner_simple.py (100%)
 delete mode 100644 src/generated_html/1658820632.92485.html
 delete mode 100644 src/json_dumps/1658820632.92485.json
 delete mode 100644 src/scan_run_1658820632.92485/tflint.txt
 delete mode 100644 src/scan_run_1658820632.92485/tfsec.txt

diff --git a/examples/database.tf b/examples/database.tf
new file mode 100644
index 0000000..584caf4
--- /dev/null
+++ b/examples/database.tf
@@ -0,0 +1,25 @@
+module "db" {
+  source = "terraform-aws-modules/rds/aws"
+  version = "~> 2.0"
+
+  identifier = "demodb"
+
+  engine            = "mysql"
+  engine_version    = "5.7.19"
+  instance_class    = "db.t2.large"
+  allocated_storage = 5
+
+  name     = "demodb"
+  username = "user"
+  password = aws_ssm_parameter.pw.value
+  port     = "3306"
+
+  maintenance_window = "Mon:00:00-Mon:03:00"
+  backup_window      = "03:00-06:00"
+}
+
+resource "aws_ssm_parameter" "pw" {
+  name = "pw"
+  type = "SecureString"
+  value = "SuperSecurePassword"
+}
\ No newline at end of file
diff --git a/examples/main.tf b/examples/main.tf
new file mode 100644
index 0000000..22a5f52
--- /dev/null
+++ b/examples/main.tf
@@ -0,0 +1,7 @@
+module "acme_finance_bucket" {
+  source      = "./modules/acme_bucket"
+  bucket_name = "finance-reports"
+  cost_centre = "CC001"
+
+  s3_logging_bucket = var.acme_s3_logging_bucket
+}
diff --git a/src/iac_scan_runner/test/test_scanner_simple.py b/examples/test_scanner_simple.py
similarity index 100%
rename from src/iac_scan_runner/test/test_scanner_simple.py
rename to examples/test_scanner_simple.py
diff --git a/src/generated_html/1658820632.92485.html b/src/generated_html/1658820632.92485.html
deleted file mode 100644
index 30763d7..0000000
--- a/src/generated_html/1658820632.92485.html
+++ /dev/null
@@ -1 +0,0 @@
-<!DOCTYPE html> <html> <style> table, th, td { border:1px solid black;}</style> <body> <h2>Scan results</h2> <table style='width:100%'> <tr> <th>Scan</th><th>Outcome</th><th>Files</th> </tr><tr><td>tflint</td><td>True</td><td>['outputs.tf', 'main.tf', 'variables.tf']</td></tr><tr><td>tfsec</td><td>True</td><td>['outputs.tf', 'main.tf', 'variables.tf']</td></tr></tr></table></body></html>
\ No newline at end of file
diff --git a/src/json_dumps/1658820632.92485.json b/src/json_dumps/1658820632.92485.json
deleted file mode 100644
index 78ddcb6..0000000
--- a/src/json_dumps/1658820632.92485.json
+++ /dev/null
@@ -1 +0,0 @@
-{"tflint": true, "tfsec": true}
\ No newline at end of file
diff --git a/src/scan_run_1658820632.92485/tflint.txt b/src/scan_run_1658820632.92485/tflint.txt
deleted file mode 100644
index e69de29..0000000
diff --git a/src/scan_run_1658820632.92485/tfsec.txt b/src/scan_run_1658820632.92485/tfsec.txt
deleted file mode 100644
index 8f094a4..0000000
--- a/src/scan_run_1658820632.92485/tfsec.txt
+++ /dev/null
@@ -1,27 +0,0 @@
-
-  times
-  ------------------------------------------
-  disk i/o             506.607µs
-  parsing HCL          8.936µs
-  evaluating values    104.034µs
-  running checks       743.522µs
-
-  counts
-  ------------------------------------------
-  files loaded         3
-  blocks               11
-  evaluated blocks     11
-  modules              0
-  module blocks        0
-  ignored checks       0
-
-  results
-  ------------------------------------------
-  critical             0
-  high                 0
-  medium               0
-  low                  0
-
-No problems detected!
-
-
\ No newline at end of file
-- 
GitLab