Skip to content

Commit 9fc6a00

Browse files
author
Kristan Kenney
committed
Add routines to manipulate webmail via backend
1 parent c90f58a commit 9fc6a00

File tree

3 files changed

+14
-0
lines changed

3 files changed

+14
-0
lines changed

bin/v-add-mail-domain

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,9 @@ if [ ! -z "$DNS_SYSTEM" ] && [ "$dkim" = 'yes' ]; then
127127
fi
128128
fi
129129

130+
# Add webmail configuration to mail domain
131+
add_webmail_config
132+
130133
#----------------------------------------------------------#
131134
# Hestia #
132135
#----------------------------------------------------------#

bin/v-delete-mail-domain

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,9 @@ if [ "$SSL" = 'yes' ]; then
6767
del_mail_ssl_config
6868
fi
6969

70+
# Delete webmail configuration
71+
del_webmail_config
72+
7073
#----------------------------------------------------------#
7174
# Hestia #
7275
#----------------------------------------------------------#

func/domain.sh

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -739,6 +739,14 @@ del_mail_ssl_config() {
739739
rm -f /usr/local/hestia/ssl/mail/mail.$domain.*
740740
}
741741

742+
del_webmail_config() {
743+
if [ ! -z "$WEB_SYSTEM" ]; then
744+
rm -f $HOMEDIR/$user/conf/mail/$domain/$WEB_SYSTEM*.conf
745+
fi
746+
if [ ! -z "$PROXY_SYSTEM" ]; then
747+
rm -f $HOMEDIR/$user/conf/mail/$domain/$PROXY_SYSTEM*.conf
748+
fi
749+
}
742750
#----------------------------------------------------------#
743751
# CMN #
744752
#----------------------------------------------------------#

0 commit comments

Comments
 (0)