Skip to content

Commit 53a708f

Browse files
author
rndinfosecguy
committedJun 27, 2019
report server updare
1 parent 5d62283 commit 53a708f

File tree

1 file changed

+17
-1
lines changed

1 file changed

+17
-1
lines changed
 

‎reporting/reportserver.py

+17-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
import _thread
2+
import time
13
import os
24

3-
os.system("python3 -m http.server --cgi 81")
5+
def start_report_server():
6+
print("Starting reporting server...")
7+
os.system("python3 -m http.server --cgi 81")
8+
9+
def renew_report():
10+
print("Generating report...")
11+
os.system("python3 report.py")
12+
13+
try:
14+
_thread.start_new_thread(start_report_server, ())
15+
while 1:
16+
_thread.start_new_thread(renew_report, ())
17+
time.sleep(60)
18+
except:
19+
print("Unable to start thread.")

0 commit comments

Comments
 (0)
Please sign in to comment.