change README file.
This commit is contained in:
parent
81553d27a2
commit
aebc2ddf89
23
README.md
23
README.md
@ -1,15 +1,14 @@
|
|||||||
# BUCT校园网自动认证
|
# BUCT校园网自动认证
|
||||||
|
用selenium实现的,主要放在树莓派上。
|
||||||
|
使用systemd管理自启动。
|
||||||
|
|
||||||
使用selenium实现,将edge的webdriver放入系统路径。准备使用树莓派进行自动定时认证。
|
用crontab理论上也行。
|
||||||
|
|
||||||
# 食用
|
由于用到了logging。所以service里面要加上`WorkingDirectory=/path/to/programe`。出错先找找权限问题。
|
||||||
## 配置selenium环境
|
|
||||||
### Windows
|
---
|
||||||
1. Python和pip安装,加入环境变量
|
|
||||||
2. 用pip安装selenium库
|
现在还是有点问题。比如说没有连接wifi的情况下,request的get会报ssl error然后直接退出。except也不好用。
|
||||||
3. 下载相应浏览器版本的webdriver并存入环境变量
|
我的解决方法就是service里面`Restart=always`,`RestartSec=60`。实测下来是能正常认证的。
|
||||||
4. run code
|
|
||||||
### Rasbian
|
用request来检测纯属闲的,本来还是拿selenium检测的。反正能跑管他呢。
|
||||||
1. 安装selenium库
|
|
||||||
`sudo apt-get install python3-selenium`
|
|
||||||
他会**自行**安装**所有**需要的库、Webdriver、chronium等等。
|
|
Loading…
x
Reference in New Issue
Block a user