一个在Debian系统上自动周期性爬取大乐透、双色球彩票开奖数据的脚本。
A script that automatically crawls the data of DaLeTou and ShuangSeQiu lottery on Debian system.
- 首先在服务器上安装**debian 8.2(64位)**操作系统
- 用FTP上传lotterygraber或者用wget的方式,把脚本文件传到服务器上:
wget "https://github.com/BEWINDOWEB/lotterygrabber/archive/master.zip"
- 运行脚本
chmod +x bwb_lottery_main.sh
./bwb_lottery_main.sh
- 如果安装顺利,会在lotterygrabber目录下生成
lotterydata
目录。 - 脚本会在星期1、3、6晚上23:00爬取中国体育彩票超级大乐透开奖号码,在星期2、4、7晚上23:00爬取中国福利彩票双色球开奖号码。数据存放在
lotterydata
目录下,样例:
2018-03-14:18028,04,19,25,30,35,04,07
2018-03-15:18029,03,09,21,25,29,01,08
2018-03-17:18030,05,18,21,28,32,09,11
2018-03-19:18031,03,08,13,17,23,05,11
2018-03-21:18032,07,10,17,32,35,05,12
2018-03-23:18032,07,10,17,32,35,05,12
- First, install the Debian 8.2 (64 bit) operating system on the server.
- Upload the lotterygraber with FTP OR use
wget "https://github.com/BEWINDOWEB/lotterygrabber/archive/master.zip"
- run the shell
chmod +x bwb_lottery_main.sh
./bwb_lottery_main.sh
- If the installation is successful, the
lotterydata
directory will be generated under the lotterygrabber directory. - The script will climb the Chinese sports lottery super lottery number at 23:00 on 1, 3, and 6 nights, and crawl the Chinese welfare lottery double color ball award number on week 2, 4 and 7 at 23:00 p.m. The data is stored in the
lotterydata
directory, sample:
2018-03-14:18028,04,19,25,30,35,04,07
2018-03-15:18029,03,09,21,25,29,01,08
2018-03-17:18030,05,18,21,28,32,09,11
2018-03-19:18031,03,08,13,17,23,05,11
2018-03-21:18032,07,10,17,32,35,05,12
2018-03-23:18032,07,10,17,32,35,05,12