-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinitAndFind.sh
More file actions
executable file
·26 lines (26 loc) · 1.18 KB
/
Copy pathinitAndFind.sh
File metadata and controls
executable file
·26 lines (26 loc) · 1.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/bin/bash
set -eu
echo ID: $(id)
export PATH=$PATH:/home/app/.local/bin/
# Ensure database is present
crawl --seed https://gioorgi.com --same-host --max-pages 3
# Reindex in case we changed the algorithms
# Enable it only if needed
# reindex
echo "TOOO Powerful to be commercial. Web Workers: ${FIND_WEB_WORKERS:-4}"
gunicorn --workers "${FIND_WEB_WORKERS:-4}" --bind 0.0.0.0:7001 --access-logfile - find.app:app &
echo ======================================================================
echo Reindex will occur every $REINDEX_INTERVAL_HOURS hours
echo ======================================================================
while true; do
date
echo ======================================================================
# Separated for the meantime
# https://www.ilpost.it/2026/05/31/
# crawl --seed https://ilpost.it/$(date +%Y/%m/%d) --include-pattern ilpost.it/$(date +%Y/%m) --max-pages 50
crawl --seed https://fatlama.substack.com --seed https://fatlama.substack.com/p/chi-ha-paura-dellopen-source \
--same-host --max-pages 100
# crawl --seed https://8bit.gioorgi.com --same-host
crawl --seed https://gioorgi.com --same-host
sleep $(( $REINDEX_INTERVAL_HOURS * 60 * 60 ))
done