kopia lustrzana https://github.com/dgtlmoon/changedetection.io
Adding README amd docker info
rodzic
325244c3a8
commit
93562afb02
|
@ -0,0 +1,20 @@
|
||||||
|
# changedetection.io
|
||||||
|
|
||||||
|
Self-hosted change monitoring of web pages.
|
||||||
|
|
||||||
|
_Why?_ Many years ago I had used a couple of web site change detection/monitoring services,
|
||||||
|
but they got bought up by larger media companies, after this, whenI logged in they
|
||||||
|
wanted _even more_ private data about me.
|
||||||
|
|
||||||
|
All I simply wanted todo was to know which pages were changing and when (and maybe see
|
||||||
|
some basic information about what those changes were)
|
||||||
|
|
||||||
|
```
|
||||||
|
git clone https://github.com/dgtlmoon/changedetection.io.git
|
||||||
|
cd changedetection.io
|
||||||
|
docker-compose up -d
|
||||||
|
|
||||||
|
```
|
||||||
|
|
||||||
|
Now visit http://127.0.0.1:5000 , The interface will now expose the UI, you can change this in the `docker-compose.yml`
|
||||||
|
|
|
@ -1,5 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
docker stop tss-node
|
|
||||||
docker rm tss-node
|
|
||||||
docker build -t tss-node .
|
|
||||||
|
|
|
@ -1,18 +1,20 @@
|
||||||
aiohttp==1.3.1
|
aiohttp
|
||||||
async-timeout==1.1.0
|
async-timeout
|
||||||
chardet==2.3.0
|
chardet==2.3.0
|
||||||
multidict==2.1.4
|
multidict
|
||||||
python-engineio
|
python-engineio
|
||||||
python_socketio==1.8.4
|
|
||||||
six==1.10.0
|
six==1.10.0
|
||||||
yarl==0.9.2
|
yarl
|
||||||
eventlet==0.19.0
|
|
||||||
flask
|
flask
|
||||||
|
|
||||||
# Actual connecting to services
|
eventlet
|
||||||
pytz
|
requests
|
||||||
phpserialize==1.3.0
|
validators
|
||||||
redis>=2.6.2
|
|
||||||
pymysql==0.8
|
bleach==3.2.1
|
||||||
bleach==1.5.0
|
|
||||||
html5lib==0.9999999 # via bleach
|
html5lib==0.9999999 # via bleach
|
||||||
|
timeago
|
||||||
|
html2text
|
||||||
|
|
||||||
|
# @notes
|
||||||
|
# - Dont install socketio, it interferes with flask_socketio
|
||||||
|
|
|
@ -60,7 +60,7 @@ class perform_site_check(Thread):
|
||||||
try:
|
try:
|
||||||
r = requests.get(self.url, headers=headers, timeout=15, verify=False)
|
r = requests.get(self.url, headers=headers, timeout=15, verify=False)
|
||||||
stripped_text_from_html = html2text.html2text(r.content.decode('utf-8'))
|
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
|
# Usually from networkIO/requests level
|
||||||
except (requests.exceptions.ConnectionError,requests.exceptions.ReadTimeout) as e:
|
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.datastore.update_watch(self.uuid, 'previous_md5', fetched_md5)
|
||||||
self.save_response_html_output(r.text)
|
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()))
|
self.datastore.update_watch(self.uuid, 'last_checked', int(time.time()))
|
||||||
|
|
|
@ -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" ]
|
||||||
|
|
|
@ -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
|
|
@ -3,7 +3,7 @@ services:
|
||||||
|
|
||||||
backend:
|
backend:
|
||||||
build: ./backend/dev-docker
|
build: ./backend/dev-docker
|
||||||
container_name: changedection-backend
|
container_name: changedetection.io-dev
|
||||||
volumes:
|
volumes:
|
||||||
- ./backend:/app
|
- ./backend:/app
|
||||||
- ./datastore:/datastore
|
- ./datastore:/datastore
|
||||||
|
|
|
@ -0,0 +1,20 @@
|
||||||
|
version: "2"
|
||||||
|
services:
|
||||||
|
|
||||||
|
backend:
|
||||||
|
build: ./backend/production-docker
|
||||||
|
container_name: changedetection.io
|
||||||
|
volumes:
|
||||||
|
- ./backend:/app
|
||||||
|
- ./datastore:/datastore
|
||||||
|
|
||||||
|
ports:
|
||||||
|
- "127.0.0.1:5000:5000"
|
||||||
|
|
||||||
|
networks:
|
||||||
|
- changenet
|
||||||
|
|
||||||
|
restart: always
|
||||||
|
|
||||||
|
networks:
|
||||||
|
changenet:
|
Ładowanie…
Reference in New Issue