From 737feadff7c026412039774de0d10931fe0c5bcc Mon Sep 17 00:00:00 2001 From: parazyd Date: Mon, 8 Feb 2021 11:27:16 +0100 Subject: contrib/init: (OpenRC) Do not fail if both rpcuser and rpcpassword are unset. This implies the .cookie file shall be used for RPC and having _both_ unset in bitcoin.conf should allow bitcoind to start. --- contrib/init/bitcoind.openrc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'contrib/init') diff --git a/contrib/init/bitcoind.openrc b/contrib/init/bitcoind.openrc index 86222295db..876d6d5893 100644 --- a/contrib/init/bitcoind.openrc +++ b/contrib/init/bitcoind.openrc @@ -69,7 +69,8 @@ start_pre() { checkconfig() { - if ! grep -qs '^rpcpassword=' "${BITCOIND_CONFIGFILE}" ; then + if grep -qs '^rpcuser=' "${BITCOIND_CONFIGFILE}" && \ + ! grep -qs '^rpcpassword=' "${BITCOIND_CONFIGFILE}" ; then eerror "" eerror "ERROR: You must set a secure rpcpassword to run bitcoind." eerror "The setting must appear in ${BITCOIND_CONFIGFILE}" -- cgit v1.2.3