Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
chain33-pai
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
szh
chain33-pai
Commits
b895f1f2
Commit
b895f1f2
authored
Apr 24, 2020
by
szh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加反馈无ssh方式
parent
96e64e01
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
2 deletions
+6
-2
app.ini
conf/app.ini
+2
-0
setting.go
pkg/setting/setting.go
+2
-0
node.go
routers/api/v1/node.go
+2
-2
No files found.
conf/app.ini
View file @
b895f1f2
...
...
@@ -81,6 +81,8 @@ DownloadUrl=https://bty33.oss-cn-shanghai.aliyuncs.com/raspberry/
VersionUrl
=
https://raspserver.biqianbao.net/pai/latestversion
FeedBackUrl
=
https://raspserver.biqianbao.net/pai/feedback
IsCompleteUrl
=
https://raspserver.biqianbao.net/pai/iscomplete
FeedBackNosshUrl
=
https://raspserver.biqianbao.net/pai/feedbacknew
IsCompleteNosshUrl
=
https://raspserver.biqianbao.net/pai/iscompletenew
RaspberryServer
=
112.124.4.47
StopPai
=
/home/pi/chain33-pai/stop-pai.sh
UploadVersionUrl
=
https://raspserver.biqianbao.net/pai/uploadinfo
...
...
pkg/setting/setting.go
View file @
b895f1f2
...
...
@@ -86,6 +86,8 @@ type Chain33_pai struct {
VersionUrl
string
FeedBackUrl
string
IsCompleteUrl
string
FeedBackNosshUrl
string
IsCompleteNosshUrl
string
RaspberryServer
string
StopPai
string
UploadVersionUrl
string
...
...
routers/api/v1/node.go
View file @
b895f1f2
...
...
@@ -352,7 +352,7 @@ func FeedBackWithoutSSH(c *gin.Context){
return
}
keyPairStream
,
_
=
json
.
Marshal
(
local_keyPair
)
resp
,
err
:=
http
.
Post
(
setting
.
Chain33Pai
.
FeedBackUrl
,
"application/json"
,
bytes
.
NewReader
(
keyPairStream
))
resp
,
err
:=
http
.
Post
(
setting
.
Chain33Pai
.
FeedBack
Nossh
Url
,
"application/json"
,
bytes
.
NewReader
(
keyPairStream
))
if
err
!=
nil
{
appG
.
Response
(
http
.
StatusOK
,
e
.
NETWORK_ERROR
,
"网络错误"
)
log
.
Println
(
err
)
...
...
@@ -376,7 +376,7 @@ func FeedBackWithoutSSH(c *gin.Context){
func
FeedBackStatusWithoutSSH
(
c
*
gin
.
Context
){
appG
:=
app
.
Gin
{
C
:
c
}
results
:=
make
(
map
[
string
]
interface
{})
resp
,
err
:=
http
.
Post
(
setting
.
Chain33Pai
.
IsCompleteUrl
,
"application/json"
,
nil
)
resp
,
err
:=
http
.
Post
(
setting
.
Chain33Pai
.
IsComplete
Nossh
Url
,
"application/json"
,
nil
)
if
err
!=
nil
{
appG
.
Response
(
http
.
StatusOK
,
e
.
NETWORK_ERROR
,
"网络错误"
)
log
.
Println
(
err
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment