Commit 528064a3 authored by szh's avatar szh

update readme

parent 8b4d8578
...@@ -154,7 +154,7 @@ response ...@@ -154,7 +154,7 @@ response
{ {
"code": 200, "code": 200,
"msg": "ok", "msg": "ok",
"data": "" "data": 1
} }
``` ```
### 重置节点,一切从新开始从0开始同步节点 内网接口 ### 重置节点,一切从新开始从0开始同步节点 内网接口
...@@ -172,7 +172,7 @@ response ...@@ -172,7 +172,7 @@ response
{ {
"code": 200, "code": 200,
"msg": "ok", "msg": "ok",
"data": "" "data": 2
} }
``` ```
### 节点更新到新版本 内网接口 ### 节点更新到新版本 内网接口
...@@ -373,7 +373,7 @@ response ...@@ -373,7 +373,7 @@ response
{ {
"code": 200, "code": 200,
"msg": "ok", "msg": "ok",
"data":"" "data":1
} }
``` ```
...@@ -390,7 +390,7 @@ response ...@@ -390,7 +390,7 @@ response
{ {
"code": 200, "code": 200,
"msg": "ok", "msg": "ok",
"data":"" "data":1
} }
此接口是为了有需要重启或者关机树莓派的时候,调用的接口 保证节点数据不损坏 此接口是为了有需要重启或者关机树莓派的时候,调用的接口 保证节点数据不损坏
``` ```
...@@ -406,7 +406,7 @@ response ...@@ -406,7 +406,7 @@ response
{ {
"code": 200, "code": 200,
"msg": "ok", "msg": "ok",
"data":"" "data":1
} }
``` ```
...@@ -421,7 +421,7 @@ response ...@@ -421,7 +421,7 @@ response
{ {
"code": 200, "code": 200,
"msg": "ok", "msg": "ok",
"data":"" "data":1
} }
``` ```
...@@ -436,7 +436,7 @@ response ...@@ -436,7 +436,7 @@ response
{ {
"code": 200, "code": 200,
"msg": "ok", "msg": "ok",
"data":"" "data":1
} }
``` ```
...@@ -451,7 +451,7 @@ response ...@@ -451,7 +451,7 @@ response
{ {
"code": 200, "code": 200,
"msg": "ok", "msg": "ok",
"data":"" "data":1
} }
``` ```
...@@ -470,6 +470,23 @@ response ...@@ -470,6 +470,23 @@ response
} }
``` ```
### 检查任务完成情况 内网接口
URL /pai/jobstatus
请求方法 post json
|参数|类型|是否必填|说明|
|job_id|int32|是|节点操作接口返回的任务id|
```
response
{
"code": 200, //200 已完成 300 未完成 500 执行出错
"msg": "ok",
"data":""
}
```
## 节点部署: ## 节点部署:
监控程序代码默认放在/home/pi目录下面 监控程序代码默认放在/home/pi目录下面
......
...@@ -3,6 +3,7 @@ package e ...@@ -3,6 +3,7 @@ package e
var MsgFlags = map[int]string{ var MsgFlags = map[int]string{
SUCCESS: "ok", SUCCESS: "ok",
ERROR: "fail", ERROR: "fail",
JOB_NOT_DONE: "未执行",
INVALID_PARAMS: "请求参数错误", INVALID_PARAMS: "请求参数错误",
DOWNLOAD_ERROR: "下载出错", DOWNLOAD_ERROR: "下载出错",
TAR_XVF_ERROR: "解压文件出错", TAR_XVF_ERROR: "解压文件出错",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment