|
@@ -1,7 +1,9 @@
|
|
|
#!/bin/bash
|
|
#!/bin/bash
|
|
|
# info: add webmail support for a domain
|
|
# info: add webmail support for a domain
|
|
|
-# options: USER DOMAIN [RESTART]
|
|
|
|
|
|
|
+# options: USER DOMAIN [RESTART] [QUIET]
|
|
|
#
|
|
#
|
|
|
|
|
+# this function adds support for webmail services
|
|
|
|
|
+# to a mail domain.
|
|
|
|
|
|
|
|
#----------------------------------------------------------#
|
|
#----------------------------------------------------------#
|
|
|
# Variable&Function #
|
|
# Variable&Function #
|
|
@@ -11,6 +13,7 @@
|
|
|
user=$1
|
|
user=$1
|
|
|
domain=$2
|
|
domain=$2
|
|
|
restart="$3"
|
|
restart="$3"
|
|
|
|
|
+quiet=$4
|
|
|
|
|
|
|
|
# Additional argument formatting
|
|
# Additional argument formatting
|
|
|
if [[ "$domain" =~ [[:upper:]] ]]; then
|
|
if [[ "$domain" =~ [[:upper:]] ]]; then
|
|
@@ -123,7 +126,9 @@ if [ "$3" = 'yes' ]; then
|
|
|
fi
|
|
fi
|
|
|
|
|
|
|
|
# Logging
|
|
# Logging
|
|
|
-log_history "enabled webmail support for $domain"
|
|
|
|
|
|
|
+if [ "$quiet" != 'yes' ]; then
|
|
|
|
|
+ log_history "enabled webmail support for $domain"
|
|
|
|
|
+fi
|
|
|
log_event "$OK" "$ARGUMENTS"
|
|
log_event "$OK" "$ARGUMENTS"
|
|
|
|
|
|
|
|
exit
|
|
exit
|