mirror of
https://github.com/aljazceru/cyphernode.git
synced 2026-01-30 17:54:32 +01:00
Spark wallet tweaking
This commit is contained in:
17
dist/setup.sh
vendored
17
dist/setup.sh
vendored
@@ -122,7 +122,7 @@ modify_permissions() {
|
||||
}
|
||||
|
||||
modify_owner() {
|
||||
local directories=("$BITCOIN_DATAPATH" "$LIGHTNING_DATAPATH" "$SPARKWALLET_DATAPATH" "$PROXY_DATAPATH" "$GATEKEEPER_DATAPATH" "$OTSCLIENT_DATAPATH")
|
||||
local directories=("$BITCOIN_DATAPATH" "$LIGHTNING_DATAPATH" "$PROXY_DATAPATH" "$GATEKEEPER_DATAPATH" "$OTSCLIENT_DATAPATH")
|
||||
local user=$(id -u $RUN_AS_USER):$(id -g $RUN_AS_USER)
|
||||
for d in "${directories[@]}"
|
||||
do
|
||||
@@ -387,6 +387,7 @@ install_docker() {
|
||||
copy_file $current_path/gatekeeper/cert.pem $GATEKEEPER_DATAPATH/certs/cert.pem 1 $SUDO_REQUIRED
|
||||
copy_file $current_path/gatekeeper/key.pem $GATEKEEPER_DATAPATH/private/key.pem 1 $SUDO_REQUIRED
|
||||
copy_file $current_path/gatekeeper/htpasswd $GATEKEEPER_DATAPATH/htpasswd 1 $SUDO_REQUIRED
|
||||
copy_file $current_path/lightning/c-lightning/nginx-spark-conf $GATEKEEPER_DATAPATH/nginx-spark-conf 1 $SUDO_REQUIRED
|
||||
fi
|
||||
|
||||
if [ ! -d $PROXY_DATAPATH ]; then
|
||||
@@ -446,7 +447,7 @@ install_docker() {
|
||||
fi
|
||||
if [ ! -d $LIGHTNING_DATAPATH ]; then
|
||||
step " [32mcreate[0m $LIGHTNING_DATAPATH"
|
||||
sudo_if_required mkdir -p $LIGHTNING_DATAPATH
|
||||
sudo_if_required mkdir -p $LIGHTNING_DATAPATH/sparkwallet
|
||||
next
|
||||
fi
|
||||
if [ -d $LIGHTNING_DATAPATH ]; then
|
||||
@@ -454,14 +455,6 @@ install_docker() {
|
||||
copy_file $current_path/lightning/c-lightning/bitcoin.conf $LIGHTNING_DATAPATH/bitcoin.conf 1 $SUDO_REQUIRED
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ $FEATURE_SPARKWALLET == true ]]; then
|
||||
if [ ! -d $SPARKWALLET_DATAPATH ]; then
|
||||
step " [32mcreate[0m $SPARKWALLET_DATAPATH"
|
||||
sudo_if_required mkdir -p $SPARKWALLET_DATAPATH
|
||||
next
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ $FEATURE_OTSCLIENT == true ]]; then
|
||||
@@ -533,7 +526,7 @@ install_docker() {
|
||||
|
||||
check_directory_owner() {
|
||||
# if one directory does not have access rights for $RUN_AS_USER, we echo 1, else we echo 0
|
||||
local directories=("$BITCOIN_DATAPATH" "$LIGHTNING_DATAPATH" "$SPARKWALLET_DATAPATH" "$PROXY_DATAPATH" "$GATEKEEPER_DATAPATH")
|
||||
local directories=("$BITCOIN_DATAPATH" "$LIGHTNING_DATAPATH" "$PROXY_DATAPATH" "$GATEKEEPER_DATAPATH")
|
||||
local status=0
|
||||
for d in "${directories[@]}"
|
||||
do
|
||||
@@ -637,7 +630,7 @@ sanity_checks_pre_install() {
|
||||
if [[ $sudo_reason == 'directories' ]]; then
|
||||
echo " [31mor check your data volumes if they have the right owner.[0m"
|
||||
echo " [31mThe owner of the following folders should be '$RUN_AS_USER':[0m"
|
||||
local directories=("$BITCOIN_DATAPATH" "$LIGHTNING_DATAPATH" "$SPARKWALLET_DATAPATH" "$PROXY_DATAPATH" "$GATEKEEPER_DATAPATH")
|
||||
local directories=("$BITCOIN_DATAPATH" "$LIGHTNING_DATAPATH" "$PROXY_DATAPATH" "$GATEKEEPER_DATAPATH")
|
||||
local status=0
|
||||
for d in "${directories[@]}"
|
||||
do
|
||||
|
||||
Reference in New Issue
Block a user