...
|
...
|
@@ -5,33 +5,43 @@ |
|
|
# 平台端
|
|
|
**仓库地址**
|
|
|
[http://git.yoho.cn/fe/yohobuy-portal-fe2](http://git.yoho.cn/fe/yohobuy-portal-fe2)
|
|
|
|
|
|
**环境发布**
|
|
|
【测试环境】
|
|
|
|
|
|
IP: 192.168.102.49
|
|
|
|
|
|
user: root
|
|
|
|
|
|
password: eW9obzk2NDY=
|
|
|
|
|
|
path: /Data/code/yohobuy-portal-fe2
|
|
|
|
|
|
build: cd /Data/code/yohobuy-portal-fe2/code && npm run build && pm2 restart yohobuy-portal-fe
|
|
|
|
|
|
|
|
|
【灰度/生产环境】
|
|
|
|
|
|
IP: 192.168.102.210
|
|
|
|
|
|
user: root
|
|
|
|
|
|
password: 123456
|
|
|
|
|
|
build: cd /home/node
|
|
|
灰度环境 sh portal.sh gray
|
|
|
生产环境 sh portal.sh master
|
|
|
|
|
|
灰度环境 sh portal.sh gray
|
|
|
|
|
|
**活动模板组件参数配置**
|
|
|
生产环境 sh portal.sh master
|
|
|
|
|
|
|
|
|
测试环境:[http://java-yoho-platform.test3.ingress.dev.yohocorp.com/platform/html/activeModule/templated_component_index.html](http://java-yoho-platform.test3.ingress.dev.yohocorp.com/platform/html/activeModule/templated_component_index.html)
|
|
|
|
|
|
**活动模板组件参数配置**
|
|
|
|
|
|
生产环境:[http://admin.portal.yohobuy.com/platform/html/activeModule/templated_component_index.html](http://admin.portal.yohobuy.com/platform/html/activeModule/templated_component_index.html)
|
|
|
测试环境:[http://java-yoho-platform.test3.ingress.dev.yohocorp.com/platform/html/activeModule/templated_component_index.html](http://java-yoho-platform.test3.ingress.dev.yohocorp.com/platform/html/activeModule/templated_component_index.html)
|
|
|
|
|
|
|
|
|
生产环境:[http://admin.portal.yohobuy.com/platform/html/activeModule/templated_component_index.html](http://admin.portal.yohobuy.com/platform/html/activeModule/templated_component_index.html)
|
|
|
|
|
|
|
|
|

|
...
|
...
|
@@ -41,11 +51,12 @@ build: cd /home/node |
|
|
|
|
|
特殊配置* (不要推到远程)
|
|
|
|
|
|
|
|
|
添加自己的环境变量
|
|
|
|
|
|
code/index.js
|
|
|

|
|
|
绕过登录校验
|
|
|
|
|
|
code/filters.js b/code/filters.js
|
|
|

|
|
|
|
...
|
...
|
@@ -54,39 +65,65 @@ code/filters.js b/code/filters.js |
|
|
|
|
|
# UFO 爬虫
|
|
|
**仓库地址**
|
|
|
|
|
|
[http://git.yoho.cn/fe/spider-ufo](http://git.yoho.cn/fe/spider-ufo)
|
|
|
|
|
|
**环境发布**
|
|
|
|
|
|
注:需要堡垒机权限,没有就找运维申请
|
|
|
|
|
|
|
|
|
登录堡垒机,选择爬虫机器
|
|
|
|
|
|

|
|
|
|
|
|
项目目录/Data/node/spider-ufo/
|
|
|
|
|
|
pull代码
|
|
|
|
|
|
pm2 restart spider-ufo 重启
|
|
|
|
|
|
pm2 logs 查看运行状态
|
|
|
|
|
|
**关键文件目录**
|
|
|
|
|
|
1.数据存储目录 /Data/node/spider-ufo/db
|
|
|
|
|
|
 毒全量商品数据(可精简)
|
|
|
|
|
|
 ufo商品与毒商品的对应关系(神箭手已停)
|
|
|
|
|
|
2.爬取日志目录 /Data/logs/node/
|
|
|
|
|
|
3.每天爬取的毒全量数据日志目录 /Data/logs/node/prices/
|
|
|
|
|
|

|
|
|
|
|
|
**常见问题定位**
|
|
|
|
|
|
1.ufo比价与毒的价格不一致
|
|
|
查询ufo与毒的货号进行对比
|
|
|
查询ufo与毒的关系文件,是否有对应关系,如果存在对应关系,则查找爬取日志找到对应商品尺码的各种日志,如果不存在对应关系,则查找毒全量商品数据是否存在该商品并对比货号(注意空格或特殊字符)
|
|
|
|
|
|
查询ufo与毒的货号进行对比
|
|
|
查询ufo与毒的关系文件,是否有对应关系,如果存在对应关系,则查找爬取日志找到对应商品尺码的各种日志,如果不存在对应关系,则查找毒全量商品数据是否存在该商品并对比货号(注意空格或特殊字符)
|
|
|
|
|
|
**后续优化**
|
|
|
1.毒全量商品数据存储精简,只需要存储ID,货号等必要信息
|
|
|
2.进行增量更新或部分增量更新,对已爬取的毒商品数据不进行抓取或每周抓取,以及根据对应关系抓取后的数据不一致时进行更新
|
|
|
3.更换存储介质
|
|
|
|
|
|
1.毒全量商品数据存储精简,只需要存储ID,货号等必要信息
|
|
|
2.进行增量更新或部分增量更新,对已爬取的毒商品数据不进行抓取或每周抓取,以及根据对应关系抓取后的数据不一致时进行更新
|
|
|
3.更换存储介质
|
|
|
|
|
|
|
|
|
**代码**
|
|
|
|
|
|

|
|
|
|
|
|
# 毒销售数据爬虫
|
|
|
|
|
|
**仓库地址**
|
|
|
|
|
|
[http://git.yoho.cn/fe/spider-du](http://git.yoho.cn/fe/spider-du) (目前已停用)
|
|
|
|
|
|
# 闲鱼UFO销售数据报表
|
|
|
**仓库地址**
|
|
|
|
|
|
[http://git.yoho.cn/fe/yoho-dashboard-ufo](http://git.yoho.cn/fe/yoho-dashboard-ufo) |
...
|
...
|
|