Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
Geth-Modification
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张蕾
Geth-Modification
Commits
35fcd2f4
Unverified
Commit
35fcd2f4
authored
Aug 03, 2018
by
Péter Szilágyi
Committed by
GitHub
Aug 03, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #17311 from karalabe/puppeth-graceful-stop
cmd/puppeth: graceful shutdown on redeploys
parents
51db5975
faf0e06e
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
17 additions
and
17 deletions
+17
-17
module_dashboard.go
cmd/puppeth/module_dashboard.go
+2
-2
module_ethstats.go
cmd/puppeth/module_ethstats.go
+2
-2
module_explorer.go
cmd/puppeth/module_explorer.go
+3
-3
module_faucet.go
cmd/puppeth/module_faucet.go
+2
-2
module_nginx.go
cmd/puppeth/module_nginx.go
+2
-2
module_node.go
cmd/puppeth/module_node.go
+3
-3
module_wallet.go
cmd/puppeth/module_wallet.go
+3
-3
No files found.
cmd/puppeth/module_dashboard.go
View file @
35fcd2f4
...
@@ -678,9 +678,9 @@ func deployDashboard(client *sshClient, network string, conf *config, config *da
...
@@ -678,9 +678,9 @@ func deployDashboard(client *sshClient, network string, conf *config, config *da
// Build and deploy the dashboard service
// Build and deploy the dashboard service
if
nocache
{
if
nocache
{
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s build --pull --no-cache && docker-compose -p %s up -d --force-recreate"
,
workdir
,
network
,
network
))
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s build --pull --no-cache && docker-compose -p %s up -d --force-recreate
--timeout 60
"
,
workdir
,
network
,
network
))
}
}
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s up -d --build --force-recreate"
,
workdir
,
network
))
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s up -d --build --force-recreate
--timeout 60
"
,
workdir
,
network
))
}
}
// dashboardInfos is returned from a dashboard status check to allow reporting
// dashboardInfos is returned from a dashboard status check to allow reporting
...
...
cmd/puppeth/module_ethstats.go
View file @
35fcd2f4
...
@@ -100,9 +100,9 @@ func deployEthstats(client *sshClient, network string, port int, secret string,
...
@@ -100,9 +100,9 @@ func deployEthstats(client *sshClient, network string, port int, secret string,
// Build and deploy the ethstats service
// Build and deploy the ethstats service
if
nocache
{
if
nocache
{
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s build --pull --no-cache && docker-compose -p %s up -d --force-recreate"
,
workdir
,
network
,
network
))
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s build --pull --no-cache && docker-compose -p %s up -d --force-recreate
--timeout 60
"
,
workdir
,
network
,
network
))
}
}
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s up -d --build --force-recreate"
,
workdir
,
network
))
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s up -d --build --force-recreate
--timeout 60
"
,
workdir
,
network
))
}
}
// ethstatsInfos is returned from an ethstats status check to allow reporting
// ethstatsInfos is returned from an ethstats status check to allow reporting
...
...
cmd/puppeth/module_explorer.go
View file @
35fcd2f4
...
@@ -38,7 +38,7 @@ ADD chain.json /chain.json
...
@@ -38,7 +38,7 @@ ADD chain.json /chain.json
RUN \
RUN \
echo '(cd ../eth-net-intelligence-api && pm2 start /ethstats.json)' > explorer.sh && \
echo '(cd ../eth-net-intelligence-api && pm2 start /ethstats.json)' > explorer.sh && \
echo '(cd ../etherchain-light && npm start &)' >> explorer.sh && \
echo '(cd ../etherchain-light && npm start &)' >> explorer.sh && \
echo '/parity/parity --chain=/chain.json --port={{.NodePort}} --tracing=on --fat-db=on --pruning=archive' >> explorer.sh
echo '
exec
/parity/parity --chain=/chain.json --port={{.NodePort}} --tracing=on --fat-db=on --pruning=archive' >> explorer.sh
ENTRYPOINT ["/bin/sh", "explorer.sh"]
ENTRYPOINT ["/bin/sh", "explorer.sh"]
`
`
...
@@ -140,9 +140,9 @@ func deployExplorer(client *sshClient, network string, chainspec []byte, config
...
@@ -140,9 +140,9 @@ func deployExplorer(client *sshClient, network string, chainspec []byte, config
// Build and deploy the boot or seal node service
// Build and deploy the boot or seal node service
if
nocache
{
if
nocache
{
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s build --pull --no-cache && docker-compose -p %s up -d --force-recreate"
,
workdir
,
network
,
network
))
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s build --pull --no-cache && docker-compose -p %s up -d --force-recreate
--timeout 60
"
,
workdir
,
network
,
network
))
}
}
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s up -d --build --force-recreate"
,
workdir
,
network
))
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s up -d --build --force-recreate
--timeout 60
"
,
workdir
,
network
))
}
}
// explorerInfos is returned from a block explorer status check to allow reporting
// explorerInfos is returned from a block explorer status check to allow reporting
...
...
cmd/puppeth/module_faucet.go
View file @
35fcd2f4
...
@@ -133,9 +133,9 @@ func deployFaucet(client *sshClient, network string, bootnodes []string, config
...
@@ -133,9 +133,9 @@ func deployFaucet(client *sshClient, network string, bootnodes []string, config
// Build and deploy the faucet service
// Build and deploy the faucet service
if
nocache
{
if
nocache
{
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s build --pull --no-cache && docker-compose -p %s up -d --force-recreate"
,
workdir
,
network
,
network
))
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s build --pull --no-cache && docker-compose -p %s up -d --force-recreate
--timeout 60
"
,
workdir
,
network
,
network
))
}
}
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s up -d --build --force-recreate"
,
workdir
,
network
))
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s up -d --build --force-recreate
--timeout 60
"
,
workdir
,
network
))
}
}
// faucetInfos is returned from a faucet status check to allow reporting various
// faucetInfos is returned from a faucet status check to allow reporting various
...
...
cmd/puppeth/module_nginx.go
View file @
35fcd2f4
...
@@ -81,9 +81,9 @@ func deployNginx(client *sshClient, network string, port int, nocache bool) ([]b
...
@@ -81,9 +81,9 @@ func deployNginx(client *sshClient, network string, port int, nocache bool) ([]b
// Build and deploy the reverse-proxy service
// Build and deploy the reverse-proxy service
if
nocache
{
if
nocache
{
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s build --pull --no-cache && docker-compose -p %s up -d --force-recreate"
,
workdir
,
network
,
network
))
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s build --pull --no-cache && docker-compose -p %s up -d --force-recreate
--timeout 60
"
,
workdir
,
network
,
network
))
}
}
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s up -d --build --force-recreate"
,
workdir
,
network
))
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s up -d --build --force-recreate
--timeout 60
"
,
workdir
,
network
))
}
}
// nginxInfos is returned from an nginx reverse-proxy status check to allow
// nginxInfos is returned from an nginx reverse-proxy status check to allow
...
...
cmd/puppeth/module_node.go
View file @
35fcd2f4
...
@@ -42,7 +42,7 @@ ADD genesis.json /genesis.json
...
@@ -42,7 +42,7 @@ ADD genesis.json /genesis.json
RUN \
RUN \
echo 'geth --cache 512 init /genesis.json' > geth.sh && \{{if .Unlock}}
echo 'geth --cache 512 init /genesis.json' > geth.sh && \{{if .Unlock}}
echo 'mkdir -p /root/.ethereum/keystore/ && cp /signer.json /root/.ethereum/keystore/' >> geth.sh && \{{end}}
echo 'mkdir -p /root/.ethereum/keystore/ && cp /signer.json /root/.ethereum/keystore/' >> geth.sh && \{{end}}
echo $'geth --networkid {{.NetworkID}} --cache 512 --port {{.Port}} --maxpeers {{.Peers}} {{.LightFlag}} --ethstats \'{{.Ethstats}}\' {{if .Bootnodes}}--bootnodes {{.Bootnodes}}{{end}} {{if .Etherbase}}--etherbase {{.Etherbase}} --mine --minerthreads 1{{end}} {{if .Unlock}}--unlock 0 --password /signer.pass --mine{{end}} --targetgaslimit {{.GasTarget}} --gasprice {{.GasPrice}}' >> geth.sh
echo $'
exec
geth --networkid {{.NetworkID}} --cache 512 --port {{.Port}} --maxpeers {{.Peers}} {{.LightFlag}} --ethstats \'{{.Ethstats}}\' {{if .Bootnodes}}--bootnodes {{.Bootnodes}}{{end}} {{if .Etherbase}}--etherbase {{.Etherbase}} --mine --minerthreads 1{{end}} {{if .Unlock}}--unlock 0 --password /signer.pass --mine{{end}} --targetgaslimit {{.GasTarget}} --gasprice {{.GasPrice}}' >> geth.sh
ENTRYPOINT ["/bin/sh", "geth.sh"]
ENTRYPOINT ["/bin/sh", "geth.sh"]
`
`
...
@@ -139,9 +139,9 @@ func deployNode(client *sshClient, network string, bootnodes []string, config *n
...
@@ -139,9 +139,9 @@ func deployNode(client *sshClient, network string, bootnodes []string, config *n
// Build and deploy the boot or seal node service
// Build and deploy the boot or seal node service
if
nocache
{
if
nocache
{
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s build --pull --no-cache && docker-compose -p %s up -d --force-recreate"
,
workdir
,
network
,
network
))
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s build --pull --no-cache && docker-compose -p %s up -d --force-recreate
--timeout 60
"
,
workdir
,
network
,
network
))
}
}
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s up -d --build --force-recreate"
,
workdir
,
network
))
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s up -d --build --force-recreate
--timeout 60
"
,
workdir
,
network
))
}
}
// nodeInfos is returned from a boot or seal node status check to allow reporting
// nodeInfos is returned from a boot or seal node status check to allow reporting
...
...
cmd/puppeth/module_wallet.go
View file @
35fcd2f4
...
@@ -37,7 +37,7 @@ ADD genesis.json /genesis.json
...
@@ -37,7 +37,7 @@ ADD genesis.json /genesis.json
RUN \
RUN \
echo 'node server.js &' > wallet.sh && \
echo 'node server.js &' > wallet.sh && \
echo 'geth --cache 512 init /genesis.json' >> wallet.sh && \
echo 'geth --cache 512 init /genesis.json' >> wallet.sh && \
echo $'geth --networkid {{.NetworkID}} --port {{.NodePort}} --bootnodes {{.Bootnodes}} --ethstats \'{{.Ethstats}}\' --cache=512 --rpc --rpcaddr=0.0.0.0 --rpccorsdomain "*" --rpcvhosts "*"' >> wallet.sh
echo $'
exec
geth --networkid {{.NetworkID}} --port {{.NodePort}} --bootnodes {{.Bootnodes}} --ethstats \'{{.Ethstats}}\' --cache=512 --rpc --rpcaddr=0.0.0.0 --rpccorsdomain "*" --rpcvhosts "*"' >> wallet.sh
RUN \
RUN \
sed -i 's/PuppethNetworkID/{{.NetworkID}}/g' dist/js/etherwallet-master.js && \
sed -i 's/PuppethNetworkID/{{.NetworkID}}/g' dist/js/etherwallet-master.js && \
...
@@ -120,9 +120,9 @@ func deployWallet(client *sshClient, network string, bootnodes []string, config
...
@@ -120,9 +120,9 @@ func deployWallet(client *sshClient, network string, bootnodes []string, config
// Build and deploy the boot or seal node service
// Build and deploy the boot or seal node service
if
nocache
{
if
nocache
{
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s build --pull --no-cache && docker-compose -p %s up -d --force-recreate"
,
workdir
,
network
,
network
))
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s build --pull --no-cache && docker-compose -p %s up -d --force-recreate
--timeout 60
"
,
workdir
,
network
,
network
))
}
}
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s up -d --build --force-recreate"
,
workdir
,
network
))
return
nil
,
client
.
Stream
(
fmt
.
Sprintf
(
"cd %s && docker-compose -p %s up -d --build --force-recreate
--timeout 60
"
,
workdir
,
network
))
}
}
// walletInfos is returned from a web wallet status check to allow reporting
// walletInfos is returned from a web wallet status check to allow reporting
...
...
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