1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 | #!/bin/bash PATH=/scripts/Enter/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin cd /scripts/social_grabber/ lockfile -r 0 .lock || exit 1 cd social_grabber source activate py35 scrapy crawl facebook scrapy crawl twitter cd .. rm -f .lock # cron job # */5 * * * * bash /scripts/social_grabber/crawler.bash &> /scripts/social_grabber/cron.log |