Get domain name when removing apps
This commit is contained in:
parent
cbd3ab2c91
commit
7b1a50c54a
|
@ -314,6 +314,9 @@ function remove_blog {
|
|||
if [[ $(app_is_installed blog) == "0" ]]; then
|
||||
return
|
||||
fi
|
||||
if grep -q "FULLBLOG_DOMAIN_NAME" $CONFIGURATION_FILE; then
|
||||
FULLBLOG_DOMAIN_NAME=$(grep "FULLBLOG_DOMAIN_NAME" $CONFIGURATION_FILE | awk -F '=' '{print $2}')
|
||||
fi
|
||||
if [ ! -d /var/www/$FULLBLOG_DOMAIN_NAME ]; then
|
||||
rm -rf /var/www/$FULLBLOG_DOMAIN_NAME
|
||||
fi
|
||||
|
|
|
@ -340,6 +340,9 @@ function remove_gnusocial {
|
|||
if [[ $(app_is_installed gnusocial) == "0" ]]; then
|
||||
return
|
||||
fi
|
||||
if grep -q "MICROBLOG_DOMAIN_NAME" $CONFIGURATION_FILE; then
|
||||
MICROBLOG_DOMAIN_NAME=$(grep "MICROBLOG_DOMAIN_NAME" $CONFIGURATION_FILE | awk -F '=' '{print $2}')
|
||||
fi
|
||||
nginx_dissite $MICROBLOG_DOMAIN_NAME
|
||||
if [ -d /var/www/$MICROBLOG_DOMAIN_NAME ]; then
|
||||
rm -rf /var/www/$MICROBLOG_DOMAIN_NAME
|
||||
|
|
|
@ -400,6 +400,9 @@ function remove_gogs {
|
|||
return
|
||||
fi
|
||||
|
||||
if grep -q "GIT_DOMAIN_NAME" $CONFIGURATION_FILE; then
|
||||
GIT_DOMAIN_NAME=$(grep "GIT_DOMAIN_NAME" $CONFIGURATION_FILE | awk -F '=' '{print $2}')
|
||||
fi
|
||||
systemctl stop gogs
|
||||
systemctl disable gogs
|
||||
nginx_dissite $GIT_DOMAIN_NAME
|
||||
|
|
|
@ -256,6 +256,9 @@ function remove_rss {
|
|||
if [[ $(app_is_installed rss) == "0" ]]; then
|
||||
return
|
||||
fi
|
||||
if grep -q "RSS_READER_DOMAIN_NAME" $CONFIGURATION_FILE; then
|
||||
RSS_READER_DOMAIN_NAME=$(grep "RSS_READER_DOMAIN_NAME" $CONFIGURATION_FILE | awk -F '=' '{print $2}')
|
||||
fi
|
||||
nginx_dissite $RSS_READER_DOMAIN_NAME
|
||||
function_check remove_onion_service
|
||||
remove_onion_service ttrss ${RSS_READER_ONION_PORT} ${RSS_MOBILE_READER_ONION_PORT}
|
||||
|
|
|
@ -236,6 +236,9 @@ function remove_wiki {
|
|||
if [[ $(app_is_installed wiki) == "0" ]]; then
|
||||
return
|
||||
fi
|
||||
if grep -q "WIKI_DOMAIN_NAME" $CONFIGURATION_FILE; then
|
||||
WIKI_DOMAIN_NAME=$(grep "WIKI_DOMAIN_NAME" $CONFIGURATION_FILE | awk -F '=' '{print $2}')
|
||||
fi
|
||||
function_check remove_onion_service
|
||||
remove_onion_service wiki ${WIKI_ONION_PORT}
|
||||
nginx_dissite $WIKI_DOMAIN_NAME
|
||||
|
|
Loading…
Reference in New Issue