Skip to content

Commit c8fe389

Browse files
authored
Merge pull request #21 from HorizenOfficial/development
Update to zend 3.0.2
2 parents fb3db0d + b7e29c0 commit c8fe389

8 files changed

+126
-4
lines changed

Dockerfile

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,9 @@ MAINTAINER cronic@horizen.io
2020

2121
SHELL ["/bin/bash", "-c"]
2222

23-
# Latest release zen 3.0.1
23+
# Latest release zen 3.0.2
2424
# TODO: Update ZEN_COMMITTISH to newest tag
25-
ARG ZEN_COMMITTISH=v3.0.1
25+
ARG ZEN_COMMITTISH=v3.0.2
2626
ARG IS_RELEASE=false
2727
# cronic <cronic@zensystem.io> http://pool.sks-keyservers.net:11371/pks/lookup?search=0x219F55740BBF7A1CE368BA45FB7053CE4991B669&op=vindex
2828
# Luigi Varriale <luigi@zensystem.io> http://pool.sks-keyservers.net:11371/pks/lookup?search=0x7C20EDC1CABFC9D1005EADBF3C80D9DD9F971AB6&op=vindex

README.md

+12
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,18 @@ docker run -d --rm --ulimit "nofile=100000:100000" -v "$(pwd)/zen-data:/data" -e
5959
```
6060
_If you cloned the repository, you can run `make run-mainnet-online`._
6161

62+
#### Adding options to the zend conf file
63+
The zend configuration file can be extended by setting the docker command to /app/rosetta-zen
64+
and using the optional -extend-zen-conf="" switch. The value of -extend-zen-conf="" will be
65+
appended to /app/zen-${NETWORK}.conf, newlines can be set as "\n".
66+
```text
67+
docker run -d --rm --ulimit "nofile=100000:100000" -v "$(pwd)/zen-data:/data" -e "MODE=ONLINE" -e "NETWORK=MAINNET" -e "PORT=8080" -p 8080:8080 -p 9033:9033 rosetta-zen:latest /app/rosetta-zen -extend-zen-conf="reindexfast=1\ndebug=rpc\ndebug=net"
68+
# this command line would append the following to /app/zen-mainnet.conf
69+
reindexfast=1
70+
debug=rpc
71+
debug=net
72+
```
73+
6274
#### Mainnet:Offline
6375
```text
6476
docker run -d --rm -e "MODE=OFFLINE" -e "NETWORK=MAINNET" -e "PORT=8081" -p 8081:8081 rosetta-zen:latest

assets/zen-mainnet.conf_default

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
##
2+
## zen.conf configuration file. Lines beginning with # are comments.
3+
##
4+
5+
# DO NOT USE THIS CONFIGURATION FILE IF YOU PLAN TO EXPOSE
6+
# ZEND'S RPC PORT PUBLICALLY (THESE INSECURE CREDENTIALS
7+
# COULD LEAD TO AN ATTACK). ROSETTA-ZEN USES THE RPC PORT
8+
# FOR INDEXING AND TRANSACTION BROADCAST BUT NEVER PROVIDES THE
9+
# CALLER ACCESS TO ZEND'S RPC PORT.
10+
11+
datadir=/data/.zen
12+
bind=0.0.0.0
13+
rpcbind=0.0.0.0
14+
bantime=15
15+
rpcallowip=0.0.0.0/0
16+
rpcallowip=::/0
17+
rpcthreads=16
18+
rpcworkqueue=1000
19+
disablewallet=1
20+
txindex=1
21+
port=9033
22+
rpcport=8231
23+
rpcuser=rosetta
24+
rpcpassword=rosetta
25+
showmetrics=0
26+
printtoconsole=1
27+
maturityheightindex=1
28+
29+
# manual pruning is not supported in zend
30+
#prune=1

assets/zen-regtest.conf_default

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
##
2+
## zen.conf configuration file. Lines beginning with # are comments.
3+
##
4+
5+
# DO NOT USE THIS CONFIGURATION FILE IF YOU PLAN TO EXPOSE
6+
# ZEND'S RPC PORT PUBLICALLY (THESE INSECURE CREDENTIALS
7+
# COULD LEAD TO AN ATTACK). ROSETTA-ZEN USES THE RPC PORT
8+
# FOR INDEXING AND TRANSACTION BROADCAST BUT NEVER PROVIDES THE
9+
# CALLER ACCESS TO ZEND'S RPC PORT.
10+
11+
datadir=/data/.zen
12+
bind=0.0.0.0
13+
rpcbind=0.0.0.0
14+
bantime=15
15+
rpcallowip=0.0.0.0/0
16+
rpcallowip=::/0
17+
rpcthreads=16
18+
rpcworkqueue=1000
19+
#disablewallet=1
20+
txindex=1
21+
port=19033
22+
rpcport=18231
23+
rpcuser=rosetta
24+
rpcpassword=rosetta
25+
showmetrics=0
26+
printtoconsole=1
27+
regtest=1
28+
maturityheightindex=1
29+
30+
# manual pruning is not supported in zend
31+
#prune=1
32+

assets/zen-testnet.conf_default

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
##
2+
## zen.conf configuration file. Lines beginning with # are comments.
3+
##
4+
5+
# DO NOT USE THIS CONFIGURATION FILE IF YOU PLAN TO EXPOSE
6+
# ZEND'S RPC PORT PUBLICALLY (THESE INSECURE CREDENTIALS
7+
# COULD LEAD TO AN ATTACK). ROSETTA-ZEN USES THE RPC PORT
8+
# FOR INDEXING AND TRANSACTION BROADCAST BUT NEVER PROVIDES THE
9+
# CALLER ACCESS TO ZEND'S RPC PORT.
10+
11+
datadir=/data/.zen
12+
bind=0.0.0.0
13+
rpcbind=0.0.0.0
14+
bantime=15
15+
rpcallowip=0.0.0.0/0
16+
rpcallowip=::/0
17+
rpcthreads=16
18+
rpcworkqueue=1000
19+
disablewallet=1
20+
txindex=1
21+
port=19033
22+
rpcport=18231
23+
rpcuser=rosetta
24+
rpcpassword=rosetta
25+
showmetrics=0
26+
printtoconsole=1
27+
testnet=1
28+
maturityheightindex=1
29+
30+
# manual pruning is not supported in zend
31+
#prune=1

entrypoint.sh

+17
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,21 @@ if [ "${MODE:-x}" = "ONLINE" ]; then
1111
/app/fetch-params.sh
1212
fi
1313

14+
args_kept=""
15+
# parse args
16+
for arg in "$@"; do
17+
case "$arg" in
18+
-e=*|-extend-zen-conf=*)
19+
cat "/app/zen-${NETWORK,,}.conf_default" > "/app/zen-${NETWORK,,}.conf"
20+
echo -e "${arg#*=}" >> "/app/zen-${NETWORK,,}.conf"
21+
shift
22+
;;
23+
*)
24+
args_kept+="${arg} "
25+
shift
26+
;;
27+
esac
28+
done
29+
30+
set -- $args_kept
1431
exec "$@"

services/network_service_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ var (
3030
defaultNetworkOptions = &types.NetworkOptionsResponse{
3131
Version: &types.Version{
3232
RosettaVersion: types.RosettaAPIVersion,
33-
NodeVersion: "3.0.1",
33+
NodeVersion: "3.0.2",
3434
MiddlewareVersion: &middlewareVersion,
3535
},
3636
Allow: &types.Allow{

services/types.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ import (
2424
const (
2525
// NodeVersion is the version of
2626
// zend core we are using.
27-
NodeVersion = "3.0.1"
27+
NodeVersion = "3.0.2"
2828

2929
// HistoricalBalanceLookup indicates
3030
// that historical balance lookup is supported.

0 commit comments

Comments
 (0)