diff --git a/.gitignore b/.gitignore
index 83e6903..3116f7d 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,5 +1,4 @@
__pycache__/
__pycache__/**
**.swp
-reports/
-reports/**
+reports/**.html
diff --git a/core/report.py b/core/report.py
index 2b7b918..53c1d4c 100644
--- a/core/report.py
+++ b/core/report.py
@@ -1,14 +1,33 @@
#!/usr/bin/env python3
from datetime import datetime
+import jinja2
+
def generateHtmlReport(data):
today = datetime.now().isoformat()[0:10].replace("-", "_")
html = _getHeader()
html += "
" \
f"Reports of {today}
"
+ dataJinja2 = dict()
+ dataJinja2['plugins'] = list()
+
+ # Env jinja2
+ env = jinja2.Environment(
+ loader=jinja2.PackageLoader("reports"),
+ autoescape=jinja2.select_autoescape()
+ )
+ # print(env.list_templates())
+ tmplIndex = env.get_template("index.html.j2")
body = str()
+ for plugin in data['system']:
+ print(plugin)
+ dataJinja2['plugins'].append(f"{plugin}.html.j2")
+
+ dataJinja2['year'] = '2023'
+ rdr = tmplIndex.render(data=dataJinja2)
+
# For sysctl
#for entry in data['sysctl']:
# body += f"Sysctl
"
@@ -34,7 +53,7 @@ def generateHtmlReport(data):
#print(body)
html += "