Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
hnt-pub
Miner
Commits
1238ca54
Commit
1238ca54
authored
3 years ago
by
Andrew Thompson
Browse files
Options
Download
Email Patches
Plain Diff
Improve reliability of run.sh
parent
9ad4db54
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
run.sh
+10
-1
run.sh
with
10 additions
and
1 deletion
+10
-1
run.sh
+
10
-
1
View file @
1238ca54
...
...
@@ -104,7 +104,7 @@ while [ $LOOP -gt 0 ]; do
for
node
in
${
nodes
[@]
}
;
do
if
[[
$(
./_build/testdev
\+
miner
$node
/rel/miner
$node
/bin/miner
$node
info in_consensus
)
=
*
true
*
]]
;
then
./_build/testdev
\+
miner
$node
/rel/miner
$node
/bin/miner
$node
genesis
export
$exported_genesis_file
if
[
$?
-eq
0
]
;
then
if
[
$?
-eq
0
-a
-f
$exported_genesis_file
]
;
then
LOOP
=
0
break
else
...
...
@@ -112,6 +112,7 @@ while [ $LOOP -gt 0 ]; do
fi
fi
done
sleep
5
done
if
[
-f
$exported_genesis_file
]
;
then
...
...
@@ -121,6 +122,14 @@ if [ -f $exported_genesis_file ]; then
for
node
in
$non_consensus_node
;
do
./_build/testdev
\+
miner
$node
/rel/miner
$node
/bin/miner
$node
genesis load
$exported_genesis_file
done
# check everyone has the chain now
for
node
in
${
nodes
[@]
}
;
do
./_build/testdev
\+
miner
$node
/rel/miner
$node
/bin/miner
$node
info height
>
/dev/null
if
[[
$?
-ne
0
]]
;
then
./_build/testdev
\+
miner
$node
/rel/miner
$node
/bin/miner
$node
genesis load
$exported_genesis_file
fi
done
else
echo
"couldn't export genesis file"
exit
1
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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