diff --git a/src/freedombone b/src/freedombone index 8bca256c..e6d32b52 100755 --- a/src/freedombone +++ b/src/freedombone @@ -690,9 +690,11 @@ function parse_args { exit 1 fi if [ ! "$DEFAULT_DOMAIN_NAME" ]; then - echo 'No default domain specified' - show_help - exit 2 + if [[ $SYSTEM_TYPE != "$VARIANT_MESH" ]]; then + echo 'No default domain specified' + show_help + exit 2 + fi fi if [ ! $MY_USERNAME ]; then echo 'No username specified' @@ -3113,6 +3115,9 @@ function create_freedns_updater { if [[ $DDNS_PROVIDER != "default@freedns.afraid.org" ]]; then return fi + if [[ $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then + return + fi FREEDNS_WGET='wget -q --read-timeout=0.0 --waitretry=5 --tries=4 https://freedns.afraid.org/dynamic/update.php?' @@ -5251,6 +5256,10 @@ function set_your_domain_name { if grep -Fxq "set_your_domain_name" $COMPLETION_FILE; then return fi + if [[ $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then + return + fi + echo "$DEFAULT_DOMAIN_NAME" > /etc/hostname hostname $DEFAULT_DOMAIN_NAME if grep -q "127.0.1.1" /etc/hosts; then @@ -5683,7 +5692,7 @@ function configure_internet_protocol { } function configure_email { - if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" ]]; then + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then return fi if grep -Fxq "configure_email" $COMPLETION_FILE; then @@ -5791,7 +5800,7 @@ function configure_email { } function create_procmail { - if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" ]]; then + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then return fi if grep -Fxq "create_procmail" $COMPLETION_FILE; then @@ -5807,7 +5816,7 @@ function create_procmail { } function spam_filtering { - if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" ]]; then + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then return fi if grep -Fxq "spam_filtering" $COMPLETION_FILE; then @@ -5941,7 +5950,7 @@ function spam_filtering { } function configure_imap { - if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" ]]; then + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then return fi if grep -Fxq "configure_imap" $COMPLETION_FILE; then @@ -6019,6 +6028,9 @@ function configure_imap { } function configure_imap_client_certs { + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then + return + fi if grep -Fxq "configure_imap_client_certs" $COMPLETION_FILE; then return fi @@ -6092,6 +6104,9 @@ function configure_imap_client_certs { } function configure_gpg { + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then + return + fi if grep -Fxq "configure_gpg" $COMPLETION_FILE; then return fi @@ -6197,7 +6212,7 @@ function encrypt_incoming_email { # encrypts incoming mail using your GPG public key # so even if an attacker gains access to the data at rest they still need # to know your GPG key password to be able to read anything - if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" ]]; then + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then return fi if grep -Fxq "encrypt_incoming_email" $COMPLETION_FILE; then @@ -6228,7 +6243,7 @@ function encrypt_outgoing_email { # encrypts outgoing mail using your GPG public key # so even if an attacker gains access to the data at rest they still need # to know your GPG key password to be able to read sent mail - if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" ]]; then + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then return fi if grep -Fxq "encrypt_outgoing_email" $COMPLETION_FILE; then @@ -6272,7 +6287,7 @@ function encrypt_outgoing_email { } function encrypt_all_email { - if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" ]]; then + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then return fi if grep -Fxq "encrypt_all_email" $COMPLETION_FILE; then @@ -6407,7 +6422,7 @@ function encrypt_all_email { } function email_client { - if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" ]]; then + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then return fi if grep -Fxq "email_client" $COMPLETION_FILE; then @@ -6540,7 +6555,7 @@ function email_client { } function email_archiving { - if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" ]]; then + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then return fi if grep -Fxq "email_archiving" $COMPLETION_FILE; then @@ -6590,7 +6605,7 @@ function email_from_address { } function create_public_mailing_list { - if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" ]]; then + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then return fi if grep -Fxq "create_public_mailing_list" $COMPLETION_FILE; then @@ -6688,7 +6703,7 @@ function create_public_mailing_list { } function create_private_mailing_list { - if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" ]]; then + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then return fi # This installation doesn't work, results in ruby errors @@ -6761,7 +6776,7 @@ function split_gpg_key_into_fragments { } function import_email { - if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" ]]; then + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_NONMAILBOX" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then return fi EMAIL_COMPLETE_MSG=' *** Freedombone mailbox installation is complete ***' @@ -6814,7 +6829,7 @@ function import_email { } function install_web_server { - if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" ]]; then + if [[ $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then return fi if grep -Fxq "install_web_server" $COMPLETION_FILE; then @@ -7405,7 +7420,7 @@ quit" > $INSTALL_DIR/batch.sql } function install_gogs { - if [[ $SYSTEM_TYPE == "$VARIANT_WRITER" || $SYSTEM_TYPE == "$VARIANT_MAILBOX" || $SYSTEM_TYPE == "$VARIANT_CLOUD" || $SYSTEM_TYPE == "$VARIANT_SOCIAL" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_CHAT" ]]; then + if [[ $SYSTEM_TYPE == "$VARIANT_WRITER" || $SYSTEM_TYPE == "$VARIANT_MAILBOX" || $SYSTEM_TYPE == "$VARIANT_CLOUD" || $SYSTEM_TYPE == "$VARIANT_SOCIAL" || $SYSTEM_TYPE == "$VARIANT_MEDIA" || $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then return fi if grep -Fxq "install_gogs" $COMPLETION_FILE; then @@ -9565,6 +9580,9 @@ function backup_github_projects { } function install_dynamicdns { + if [[ $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then + return + fi if grep -Fxq "install_dynamicdns" $COMPLETION_FILE; then return fi