Tidying
This commit is contained in:
parent
d441d19470
commit
ad05156395
|
@ -185,7 +185,8 @@ function remove_dokuwiki {
|
|||
if [ -d /usr/share/dokuwiki ]; then
|
||||
rm -rf /usr/share/dokuwiki
|
||||
fi
|
||||
remove_completion_param install_dokuwiki
|
||||
remove_completion_param "install_dokuwiki"
|
||||
remove_completion_param "dokuwiki domain"
|
||||
}
|
||||
|
||||
function get_dokuwiki_admin_password {
|
||||
|
@ -278,6 +279,7 @@ function install_dokuwiki {
|
|||
fi
|
||||
|
||||
DOKUWIKI_ONION_HOSTNAME=$(add_onion_service dokuwiki 80 ${DOKUWIKI_ONION_PORT})
|
||||
set_completion_param "dokuwiki domain" "${DOKUWIKI_DOMAIN_NAME}"
|
||||
|
||||
if [[ $ONION_ONLY == "no" ]]; then
|
||||
echo 'server {' > /etc/nginx/sites-available/$DOKUWIKI_DOMAIN_NAME
|
||||
|
@ -564,7 +566,6 @@ function install_dokuwiki {
|
|||
chmod 600 /home/$MY_USERNAME/README
|
||||
fi
|
||||
|
||||
set_completion_param "dokuwiki domain" "$DOKUWIKI_DOMAIN_NAME"
|
||||
APP_INSTALLED=1
|
||||
}
|
||||
|
||||
|
|
|
@ -345,7 +345,7 @@ function remove_gogs {
|
|||
rm /etc/systemd/system/gogs.service
|
||||
rm -rf /home/${GOGS_USERNAME}/*
|
||||
remove_onion_service gogs ${GIT_ONION_PORT} 9418
|
||||
remove_completion_param install_gogs
|
||||
remove_completion_param "install_gogs"
|
||||
sed -i '/gogs /d' $COMPLETION_FILE
|
||||
}
|
||||
|
||||
|
@ -566,7 +566,7 @@ function install_gogs {
|
|||
echo $'Added onion site for Gogs'
|
||||
fi
|
||||
|
||||
systemctl restart tor
|
||||
systemctl reload tor
|
||||
|
||||
function_check wait_for_onion_service
|
||||
wait_for_onion_service 'gogs'
|
||||
|
@ -583,11 +583,8 @@ function install_gogs {
|
|||
chmod 600 /home/${MY_USERNAME}/README
|
||||
fi
|
||||
|
||||
if ! grep -q "gogs onion domain" ${COMPLETION_FILE}; then
|
||||
echo "gogs onion domain:${GIT_ONION_HOSTNAME}" >> ${COMPLETION_FILE}
|
||||
else
|
||||
sed -i "s|gogs onion domain.*|gogs onion domain:${GIT_ONION_HOSTNAME}|g" ${COMPLETION_FILE}
|
||||
fi
|
||||
set_completion_param "gogs domain" "$GIT_DOMAIN_NAME"
|
||||
set_completion_param "gogs onion domain" "$GIT_ONION_HOSTNAME"
|
||||
|
||||
function_check add_ddns_domain
|
||||
add_ddns_domain ${GIT_DOMAIN_NAME}
|
||||
|
|
|
@ -329,9 +329,9 @@ function remove_htmly {
|
|||
remove_config_param HTMLY_CODE
|
||||
function_check remove_onion_service
|
||||
remove_onion_service htmly ${HTMLY_ONION_PORT}
|
||||
remove_completion_param install_htmly
|
||||
sed -i '/Htmly .*/d' $COMPLETION_FILE
|
||||
sed -i '/htmly .*/d' $COMPLETION_FILE
|
||||
remove_completion_param "install_htmly"
|
||||
sed -i '/Htmly /d' $COMPLETION_FILE
|
||||
sed -i '/htmly /d' $COMPLETION_FILE
|
||||
}
|
||||
|
||||
function get_htmly_admin_password {
|
||||
|
|
|
@ -404,7 +404,7 @@ function install_irc_client {
|
|||
echo " port = \"${IRC_PORT}\";" >> /home/${MY_USERNAME}/.irssi/config
|
||||
echo ' use_ssl = "yes";' >> /home/${MY_USERNAME}/.irssi/config
|
||||
else
|
||||
IRC_ONION_HOSTNAME=$(cat ${COMPLETION_FILE} | grep "irc onion domain" | awk -F ':' '{print $2}')
|
||||
IRC_ONION_HOSTNAME=$(cat ${COMPLETION_FILE} | grep "irc onion domain" | head -n 1 | awk -F ':' '{print $2}')
|
||||
echo " port = \"${IRC_ONION_PORT}\";" >> /home/${MY_USERNAME}/.irssi/config
|
||||
echo ' use_ssl = "no";' >> /home/${MY_USERNAME}/.irssi/config
|
||||
fi
|
||||
|
|
|
@ -86,6 +86,7 @@ function remove_onion_service {
|
|||
shred -zu /var/lib/tor/hidden_service_${onion_service_name}/*
|
||||
rm -rf /var/lib/tor/hidden_service_${onion_service_name}
|
||||
fi
|
||||
remove_completion_param "${onion_service_name} onion domain"
|
||||
onion_update
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue