From 5a59db654909a4485d856d4c0e95f7984f1fafd5 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Mon, 7 Sep 2015 22:18:32 +0100 Subject: [PATCH] Hubzilla install switch --- src/freedombone | 14 +++++++++++++- src/freedombone-config | 6 ++++++ 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/src/freedombone b/src/freedombone index 4a482faf..ba9ec4f7 100755 --- a/src/freedombone +++ b/src/freedombone @@ -42,6 +42,9 @@ INSTALLING_ON_BBB="no" # Version number of this script VERSION="1.01" +# whether to enable hubzilla or redmatrix +ENABLE_HUBZILLA="no" + # Different system variants which may be specified within # the SYSTEM_TYPE option VARIANT_FULL="full" @@ -789,6 +792,9 @@ function read_configuration { fi if [ -f $CONFIGURATION_FILE ]; then + if grep -q "ENABLE_HUBZILLA" $CONFIGURATION_FILE; then + ENABLE_HUBZILLA=$(grep "ENABLE_HUBZILLA" $CONFIGURATION_FILE | awk -F '=' '{print $2}') + fi if grep -q "TRACKER_PORT" $CONFIGURATION_FILE; then TRACKER_PORT=$(grep "TRACKER_PORT" $CONFIGURATION_FILE | awk -F '=' '{print $2}') fi @@ -9869,6 +9875,9 @@ function install_redmatrix { if [ ! $REDMATRIX_DOMAIN_NAME ]; then return fi + if [[ $ENABLE_HUBZILLA != "no" ]]; then + return + fi install_mariadb get_mariadb_password @@ -10135,6 +10144,9 @@ function install_hubzilla { if [ ! $HUBZILLA_DOMAIN_NAME ]; then return fi + if [[ $ENABLE_HUBZILLA == "no" ]]; then + return + fi install_mariadb get_mariadb_password @@ -11259,7 +11271,7 @@ install_wiki install_blog install_gnu_social install_redmatrix -#install_hubzilla +install_hubzilla install_dlna_server configure_firewall_for_dlna install_mediagoblin diff --git a/src/freedombone-config b/src/freedombone-config index f284a608..d36044b7 100755 --- a/src/freedombone-config +++ b/src/freedombone-config @@ -260,6 +260,9 @@ function save_configuration_file { if [ $DH_KEYLENGTH ]; then echo "DH_KEYLENGTH=$DH_KEYLENGTH" >> $CONFIGURATION_FILE fi + if [ $ENABLE_HUBZILLA ]; then + echo "ENABLE_HUBZILLA=$ENABLE_HUBZILLA" >> $CONFIGURATION_FILE + fi } # test a domain name to see if it's valid @@ -1536,6 +1539,9 @@ function read_configuration { fi if [ -f $CONFIGURATION_FILE ]; then + if grep -q "ENABLE_HUBZILLA" $CONFIGURATION_FILE; then + ENABLE_HUBZILLA=$(grep "ENABLE_HUBZILLA" $CONFIGURATION_FILE | awk -F '=' '{print $2}') + fi if grep -q "ENABLE_SOCIAL_KEY_MANAGEMENT" $CONFIGURATION_FILE; then ENABLE_SOCIAL_KEY_MANAGEMENT=$(grep "ENABLE_SOCIAL_KEY_MANAGEMENT" $CONFIGURATION_FILE | awk -F '=' '{print $2}') fi