CERC_PLUGINS_DIR
This commit is contained in:
parent
a74c9b3814
commit
b3f166266e
@ -7,8 +7,8 @@ fi
|
|||||||
ETHERBASE=`cat /opt/testnet/build/el/accounts.csv | head -1 | cut -d',' -f2`
|
ETHERBASE=`cat /opt/testnet/build/el/accounts.csv | head -1 | cut -d',' -f2`
|
||||||
NETWORK_ID=`cat /opt/testnet/el/el-config.yaml | grep 'chain_id' | awk '{ print $2 }'`
|
NETWORK_ID=`cat /opt/testnet/el/el-config.yaml | grep 'chain_id' | awk '{ print $2 }'`
|
||||||
NETRESTRICT=`ip addr | grep inet | grep -v '127.0' | awk '{print $2}'`
|
NETRESTRICT=`ip addr | grep inet | grep -v '127.0' | awk '{print $2}'`
|
||||||
ETH_DATADIR="${ETH_DATADIR:-$HOME/ethdata}"
|
CERC_ETH_DATADIR="${CERC_ETH_DATADIR:-$HOME/ethdata}"
|
||||||
PLUGINS_DIR="${PLUGINS_DIR:-$ETH_DATADIR/plugins}"
|
CERC_PLUGINS_DIR="${CERC_PLUGINS_DIR:-/usr/local/lib/plugeth}"
|
||||||
|
|
||||||
cd /opt/testnet/build/el
|
cd /opt/testnet/build/el
|
||||||
python3 -m http.server 9898 &
|
python3 -m http.server 9898 &
|
||||||
@ -35,7 +35,7 @@ trap 'cleanup' SIGINT SIGTERM
|
|||||||
|
|
||||||
if [ "true" == "$RUN_BOOTNODE" ]; then
|
if [ "true" == "$RUN_BOOTNODE" ]; then
|
||||||
$START_CMD \
|
$START_CMD \
|
||||||
--datadir="$ETH_DATADIR" \
|
--datadir="${CERC_ETH_DATADIR}" \
|
||||||
--nodekeyhex="${BOOTNODE_KEY}" \
|
--nodekeyhex="${BOOTNODE_KEY}" \
|
||||||
--nodiscover \
|
--nodiscover \
|
||||||
--ipcdisable \
|
--ipcdisable \
|
||||||
@ -96,24 +96,14 @@ else
|
|||||||
--statediff.workers=${CERC_STATEDIFF_WORKERS:-1} \
|
--statediff.workers=${CERC_STATEDIFF_WORKERS:-1} \
|
||||||
--statediff.writing=true"
|
--statediff.writing=true"
|
||||||
|
|
||||||
if [ -f "/usr/local/lib/plugeth/statediff.so" ]; then
|
if [ -d "${CERC_PLUGINS_DIR}" ]; then
|
||||||
# With plugeth, we separate the statediff options by prefixing with ' -- '
|
# With plugeth, we separate the statediff options by prefixing with ' -- '
|
||||||
STATEDIFF_OPTS=" -- ${STATEDIFF_OPTS}"
|
STATEDIFF_OPTS="--pluginsdir "${CERC_PLUGINS_DIR}" -- ${STATEDIFF_OPTS}"
|
||||||
|
|
||||||
# Check if the plugins directory exists
|
|
||||||
if [ ! -d "${PLUGINS_DIR}" ]; then
|
|
||||||
mkdir -p "${PLUGINS_DIR}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# And copy our plugin into place (if needed).
|
|
||||||
if [ ! -f "${PLUGINS_DIR}/statediff.so" ]; then
|
|
||||||
cp -f "/usr/local/lib/plugeth/statediff.so" "${PLUGINS_DIR}/statediff.so"
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
$START_CMD \
|
$START_CMD \
|
||||||
--datadir="${ETH_DATADIR}" \
|
--datadir="${CERC_ETH_DATADIR}" \
|
||||||
--bootnodes="${ENODE}" \
|
--bootnodes="${ENODE}" \
|
||||||
--allow-insecure-unlock \
|
--allow-insecure-unlock \
|
||||||
--http \
|
--http \
|
||||||
|
Loading…
Reference in New Issue
Block a user