Skip to content

Commit

Permalink
Allow providing a (json) list of trusted cidrs to write to the config
Browse files Browse the repository at this point in the history
  • Loading branch information
cmmarslender committed May 30, 2024
1 parent 2c47580 commit efa4466
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,14 @@ if [[ -n ${full_node_peer} ]]; then
' "$CHIA_ROOT/config/config.yaml"
fi

if [[ -n ${trusted_cidrs} ]]; then
echo "Changing trusted cidr setting in config.yaml to value: $trusted_cidrs"
yq -i '
.wallet.trusted_cidrs = env(trusted_cidrs) |
.full_node.trusted_cidrs = env(trusted_cidrs)
' "$CHIA_ROOT/config/config.yaml"
fi

if [[ ${log_to_file} != 'true' ]]; then
sed -i 's/log_stdout: false/log_stdout: true/g' "$CHIA_ROOT/config/config.yaml"
else
Expand Down

0 comments on commit efa4466

Please sign in to comment.