Don't install hubzilla on onion-only variants
This commit is contained in:
parent
a69afb25b1
commit
e8a6d8fdd7
|
@ -137,57 +137,57 @@ function configure_interactive_hubzilla {
|
||||||
|
|
||||||
function install_interactive_hubzilla {
|
function install_interactive_hubzilla {
|
||||||
if [[ $ONION_ONLY != "no" ]]; then
|
if [[ $ONION_ONLY != "no" ]]; then
|
||||||
HUBZILLA_DOMAIN_NAME='hubzilla.local'
|
return
|
||||||
else
|
fi
|
||||||
HUBZILLA_DETAILS_COMPLETE=
|
|
||||||
while [ ! $HUBZILLA_DETAILS_COMPLETE ]
|
HUBZILLA_DETAILS_COMPLETE=
|
||||||
do
|
while [ ! $HUBZILLA_DETAILS_COMPLETE ]
|
||||||
data=$(tempfile 2>/dev/null)
|
do
|
||||||
trap "rm -f $data" 0 1 2 5 15
|
data=$(tempfile 2>/dev/null)
|
||||||
if [[ $DDNS_PROVIDER == "default@freedns.afraid.org" ]]; then
|
trap "rm -f $data" 0 1 2 5 15
|
||||||
dialog --backtitle $"Freedombone Configuration" \
|
if [[ $DDNS_PROVIDER == "default@freedns.afraid.org" ]]; then
|
||||||
--title $"Hubzilla Configuration" \
|
dialog --backtitle $"Freedombone Configuration" \
|
||||||
--form $"\nPlease enter your Hubzilla details.\n\nIMPORTANT: This should be a domain name which is supported by Let's Encrypt:" 14 55 3 \
|
--title $"Hubzilla Configuration" \
|
||||||
$"Domain:" 1 1 "$(grep 'HUBZILLA_DOMAIN_NAME' temp.cfg | awk -F '=' '{print $2}')" 1 16 33 40 \
|
--form $"\nPlease enter your Hubzilla details.\n\nIMPORTANT: This should be a domain name which is supported by Let's Encrypt:" 14 55 3 \
|
||||||
$"Code:" 2 1 "$(grep 'HUBZILLA_CODE' temp.cfg | awk -F '=' '{print $2}')" 2 16 33 255 \
|
$"Domain:" 1 1 "$(grep 'HUBZILLA_DOMAIN_NAME' temp.cfg | awk -F '=' '{print $2}')" 1 16 33 40 \
|
||||||
2> $data
|
$"Code:" 2 1 "$(grep 'HUBZILLA_CODE' temp.cfg | awk -F '=' '{print $2}')" 2 16 33 255 \
|
||||||
|
2> $data
|
||||||
|
else
|
||||||
|
dialog --backtitle $"Freedombone Configuration" \
|
||||||
|
--title $"Hubzilla Configuration" \
|
||||||
|
--form $"\nPlease enter your Hubzilla details\n\nIMPORTANT: This should be a domain name which is supported by Let's Encrypt:" 11 55 3 \
|
||||||
|
$"Domain:" 1 1 "$(grep 'HUBZILLA_DOMAIN_NAME' temp.cfg | awk -F '=' '{print $2}')" 1 16 33 40 \
|
||||||
|
2> $data
|
||||||
|
fi
|
||||||
|
sel=$?
|
||||||
|
case $sel in
|
||||||
|
1) exit 1;;
|
||||||
|
255) exit 1;;
|
||||||
|
esac
|
||||||
|
HUBZILLA_DOMAIN_NAME=$(cat $data | sed -n 1p)
|
||||||
|
if [ $HUBZILLA_DOMAIN_NAME ]; then
|
||||||
|
TEST_DOMAIN_NAME=$HUBZILLA_DOMAIN_NAME
|
||||||
|
validate_domain_name
|
||||||
|
if [[ $TEST_DOMAIN_NAME != $HUBZILLA_DOMAIN_NAME ]]; then
|
||||||
|
HUBZILLA_DOMAIN_NAME=
|
||||||
|
dialog --title $"Domain name validation" --msgbox "$TEST_DOMAIN_NAME" 15 50
|
||||||
else
|
else
|
||||||
dialog --backtitle $"Freedombone Configuration" \
|
if [[ $DDNS_PROVIDER == "default@freedns.afraid.org" ]]; then
|
||||||
--title $"Hubzilla Configuration" \
|
HUBZILLA_CODE=$(cat $data | sed -n 2p)
|
||||||
--form $"\nPlease enter your Hubzilla details\n\nIMPORTANT: This should be a domain name which is supported by Let's Encrypt:" 11 55 3 \
|
validate_freedns_code "$HUBZILLA_CODE"
|
||||||
$"Domain:" 1 1 "$(grep 'HUBZILLA_DOMAIN_NAME' temp.cfg | awk -F '=' '{print $2}')" 1 16 33 40 \
|
if [ ! $VALID_CODE ]; then
|
||||||
2> $data
|
HUBZILLA_DOMAIN_NAME=
|
||||||
fi
|
|
||||||
sel=$?
|
|
||||||
case $sel in
|
|
||||||
1) exit 1;;
|
|
||||||
255) exit 1;;
|
|
||||||
esac
|
|
||||||
HUBZILLA_DOMAIN_NAME=$(cat $data | sed -n 1p)
|
|
||||||
if [ $HUBZILLA_DOMAIN_NAME ]; then
|
|
||||||
TEST_DOMAIN_NAME=$HUBZILLA_DOMAIN_NAME
|
|
||||||
validate_domain_name
|
|
||||||
if [[ $TEST_DOMAIN_NAME != $HUBZILLA_DOMAIN_NAME ]]; then
|
|
||||||
HUBZILLA_DOMAIN_NAME=
|
|
||||||
dialog --title $"Domain name validation" --msgbox "$TEST_DOMAIN_NAME" 15 50
|
|
||||||
else
|
|
||||||
if [[ $DDNS_PROVIDER == "default@freedns.afraid.org" ]]; then
|
|
||||||
HUBZILLA_CODE=$(cat $data | sed -n 2p)
|
|
||||||
validate_freedns_code "$HUBZILLA_CODE"
|
|
||||||
if [ ! $VALID_CODE ]; then
|
|
||||||
HUBZILLA_DOMAIN_NAME=
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
if [ $HUBZILLA_DOMAIN_NAME ]; then
|
fi
|
||||||
HUBZILLA_DETAILS_COMPLETE="yes"
|
if [ $HUBZILLA_DOMAIN_NAME ]; then
|
||||||
fi
|
HUBZILLA_DETAILS_COMPLETE="yes"
|
||||||
done
|
fi
|
||||||
# save the results in the config file
|
done
|
||||||
write_config_param "HUBZILLA_DOMAIN_NAME" "$HUBZILLA_DOMAIN_NAME"
|
# save the results in the config file
|
||||||
write_config_param "HUBZILLA_CODE" "$HUBZILLA_CODE"
|
write_config_param "HUBZILLA_DOMAIN_NAME" "$HUBZILLA_DOMAIN_NAME"
|
||||||
fi
|
write_config_param "HUBZILLA_CODE" "$HUBZILLA_CODE"
|
||||||
}
|
}
|
||||||
|
|
||||||
function change_password_hubzilla {
|
function change_password_hubzilla {
|
||||||
|
|
Loading…
Reference in New Issue