Skip to content

Commit da223fe

Browse files
committed
fix(docker): solve issues with specifying config file path
1 parent a8872c6 commit da223fe

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

docker/witnet-rust/runner.sh

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ PUBLIC_ADDR_DISCOVERY=${PUBLIC_ADDR_DISCOVERY:-"true"}
4343
LOG_LEVEL=${LOG_LEVEL:-"info"}
4444

4545
# Run the migrator (e.g. move RocksDB data from "./witnet" into "./witnet/storage")
46-
./migrator.sh
46+
./migrator.sh $@
4747

4848
# Change directory into the file system root so that all paths are absolute when using "docker exec"
4949
cd /
@@ -52,11 +52,12 @@ cd /
5252
while true; do
5353
# Run the public address detector if enabled
5454
if [[ "$PUBLIC_ADDR_DISCOVERY" == "true" ]]; then
55-
/tmp/ip_detector.sh
55+
/tmp/ip_detector.sh $@
5656
fi
5757

5858
# Run the node itself, using configuration from the default directory and passing down any arguments that may be
5959
# appended when running "docker run"
60-
RUST_LOG=witnet=$LOG_LEVEL /tmp/witnet-raw -c "$CONFIG_FILE" "$COMMAND" || echo "$ERROR_BANNER"
60+
echo "Running as 'RUST_LOG=witnet=$LOG_LEVEL /tmp/witnet-raw -c \"$CONFIG_FILE\" $COMMAND'"
61+
RUST_LOG=witnet=$LOG_LEVEL /tmp/witnet-raw -c "$CONFIG_FILE" $COMMAND || echo "$ERROR_BANNER"
6162
sleep 30
6263
done

docker/witnet-rust/testnet-1/witnet.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ data_request_max_retrievals_per_epoch = 30
7575
data_request_timeout_milliseconds = 2000
7676
# Path for the `genesis_block.json` file that contains the initial wit allocations that need to be built into the first
7777
# block in the block chain.
78-
genesis_path = ".witnet/config/testnet-1/genesis_block.json"
78+
genesis_path = "/tmp/testnet-1/genesis_block.json"
7979
# `mint_external_address` and `mint_external_percentage` enable splitting the mint reward between the node's
8080
# own address and an "external" address, e.g. a the address of a wallet. `mint_external_percentage` indicates
8181
# the percentage of the block rewards that will be assigned to `mint_external_address` (50% by default)

0 commit comments

Comments
 (0)