From 2f96fe2a73c2ddfba6a9c5670b1ee658cbfca071 Mon Sep 17 00:00:00 2001 From: Luke Childs Date: Thu, 12 Dec 2019 13:07:00 +0700 Subject: [PATCH] Use mutliline commands in examples for better readability --- README.md | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index b75b767..ac6c266 100644 --- a/README.md +++ b/README.md @@ -25,13 +25,17 @@ docker exec -it bitcoind bitcoin-cli getnetworkinfo To access JSON-RPC from other services you'll also need to expose port 8332. You probably only want this available to localhost: ``` -docker --name bitcoind run -v $HOME/.bitcoin:/data/.bitcoin -p 8333:8333 -p 127.0.0.1:8332:8332 lukechilds/bitcoind +docker --name bitcoind run -v $HOME/.bitcoin:/data/.bitcoin \ + -p 8333:8333 \ + -p 127.0.0.1:8332:8332 \ + lukechilds/bitcoind ``` You could now query JSON-RPC via cURL like so: ``` -curl --data '{"jsonrpc":"1.0","id":"curltext","method":"getnetworkinfo"}' http://$(cat $HOME/.bitcoin/.cookie)@127.0.0.1:8332 +curl --data '{"jsonrpc":"1.0","id":"curltext","method":"getnetworkinfo"}' \ + http://$(cat $HOME/.bitcoin/.cookie)@127.0.0.1:8332 ``` ### CLI Arguments