mirror of
https://github.com/rootzoll/raspiblitz.git
synced 2025-02-28 16:58:03 +01:00
3733 CLN GRPC > JRPC (#3741)
* change exit code * change to cln_jrpc * deactivate the cln_grpc settings
This commit is contained in:
parent
83a6413bb4
commit
e998f19a8c
2 changed files with 15 additions and 14 deletions
|
@ -95,25 +95,26 @@ if [ "$1" = "update-config" ]; then
|
|||
elif [ "${lightning}" == "cl" ]; then
|
||||
|
||||
echo "# CONFIG Web API Lightning --> CL"
|
||||
sed -i "s/^ln_node=.*/ln_node=cln_grpc/g" ./.env
|
||||
sed -i "s/^ln_node=.*/ln_node=cln_jrpc/g" ./.env
|
||||
sed -i "s/^cln_jrpc_path=.*/cln_jrpc_path="/mnt/hdd/app-data/.lightning/bitcoin/lightning-rpc"/g" ./.env
|
||||
|
||||
# make sure cln-grpc is on
|
||||
sudo /home/admin/config.scripts/cl-plugin.cln-grpc.sh on mainnet
|
||||
# sudo /home/admin/config.scripts/cl-plugin.cln-grpc.sh on mainnet
|
||||
|
||||
# get hex values of pem files
|
||||
hexClient=$(sudo xxd -p -c2000 /home/bitcoin/.lightning/bitcoin/client.pem)
|
||||
hexClientKey=$(sudo xxd -p -c2000 /home/bitcoin/.lightning/bitcoin/client-key.pem)
|
||||
hexCa=$(sudo xxd -p -c2000 /home/bitcoin/.lightning/bitcoin/ca.pem)
|
||||
if [ "${hexClient}" == "" ]; then
|
||||
echo "# FAIL /home/bitcoin/.lightning/bitcoin/*.pem files maybe missing"
|
||||
fi
|
||||
# hexClient=$(sudo xxd -p -c2000 /home/bitcoin/.lightning/bitcoin/client.pem)
|
||||
# hexClientKey=$(sudo xxd -p -c2000 /home/bitcoin/.lightning/bitcoin/client-key.pem)
|
||||
# hexCa=$(sudo xxd -p -c2000 /home/bitcoin/.lightning/bitcoin/ca.pem)
|
||||
# if [ "${hexClient}" == "" ]; then
|
||||
# echo "# FAIL /home/bitcoin/.lightning/bitcoin/*.pem files maybe missing"
|
||||
# fi
|
||||
|
||||
# update config with hex values
|
||||
sed -i "s/^cln_grpc_cert=.*/cln_grpc_cert=${hexClient}/g" ./.env
|
||||
sed -i "s/^cln_grpc_key=.*/cln_grpc_key=${hexClientKey}/g" ./.env
|
||||
sed -i "s/^cln_grpc_ca=.*/cln_grpc_ca=${hexCa}/g" ./.env
|
||||
sed -i "s/^cln_grpc_ip=.*/cln_grpc_ip=127.0.0.1/g" ./.env
|
||||
sed -i "s/^cln_grpc_port=.*/cln_grpc_port=4772/g" ./.env
|
||||
# sed -i "s/^cln_grpc_cert=.*/cln_grpc_cert=${hexClient}/g" ./.env
|
||||
# sed -i "s/^cln_grpc_key=.*/cln_grpc_key=${hexClientKey}/g" ./.env
|
||||
# sed -i "s/^cln_grpc_ca=.*/cln_grpc_ca=${hexCa}/g" ./.env
|
||||
# sed -i "s/^cln_grpc_ip=.*/cln_grpc_ip=127.0.0.1/g" ./.env
|
||||
# sed -i "s/^cln_grpc_port=.*/cln_grpc_port=4772/g" ./.env
|
||||
|
||||
else
|
||||
echo "# CONFIG Web API Lightning --> OFF"
|
||||
|
|
|
@ -118,7 +118,7 @@ if [ "$1" = "install" ]; then
|
|||
# check if the binary is already installed
|
||||
if [ -f /usr/local/bin/lightningd ]; then
|
||||
echo "Core Lightning binary already installed - done"
|
||||
exit 1
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# download and verify the source from github
|
||||
|
|
Loading…
Add table
Reference in a new issue