Adding README amd docker info

This commit is contained in:
Leigh Morresi
2021-01-27 20:51:55 +01:00
parent 325244c3a8
commit 93562afb02
8 changed files with 86 additions and 19 deletions

View File

@@ -1,5 +0,0 @@
#!/bin/bash
docker stop tss-node
docker rm tss-node
docker build -t tss-node .

View File

@@ -1,18 +1,20 @@
aiohttp==1.3.1
async-timeout==1.1.0
aiohttp
async-timeout
chardet==2.3.0
multidict==2.1.4
multidict
python-engineio
python_socketio==1.8.4
six==1.10.0
yarl==0.9.2
eventlet==0.19.0
yarl
flask
# Actual connecting to services
pytz
phpserialize==1.3.0
redis>=2.6.2
pymysql==0.8
bleach==1.5.0
eventlet
requests
validators
bleach==3.2.1
html5lib==0.9999999 # via bleach
timeago
html2text
# @notes
# - Dont install socketio, it interferes with flask_socketio

View File

@@ -60,7 +60,7 @@ class perform_site_check(Thread):
try:
r = requests.get(self.url, headers=headers, timeout=15, verify=False)
stripped_text_from_html = html2text.html2text(r.content.decode('utf-8'))
self.save_response_stripped_output(stripped_text_from_html)
# Usually from networkIO/requests level
except (requests.exceptions.ConnectionError,requests.exceptions.ReadTimeout) as e:
@@ -90,6 +90,7 @@ class perform_site_check(Thread):
self.datastore.update_watch(self.uuid, 'previous_md5', fetched_md5)
self.save_response_html_output(r.text)
self.save_response_stripped_output(stripped_text_from_html)
self.datastore.update_watch(self.uuid, 'last_checked', int(time.time()))

View File

@@ -0,0 +1,9 @@
FROM python:3.8-buster
COPY requirements.txt /tmp/requirements.txt
RUN pip3 install -r /tmp/requirements.txt
# So that it can find the certs
WORKDIR /app
CMD [ "python", "/app/backend.py" ]

View File

@@ -0,0 +1,20 @@
aiohttp
async-timeout
chardet==2.3.0
multidict
python-engineio
six==1.10.0
yarl
flask
eventlet
requests
validators
bleach==3.2.1
html5lib==0.9999999 # via bleach
timeago
html2text
# @notes
# - Dont install socketio, it interferes with flask_socketio