This commit is contained in:
th33xitus
2020-07-23 11:04:23 +02:00
parent a2042ec378
commit 80344ec41c
3 changed files with 8 additions and 14 deletions

View File

@@ -128,15 +128,6 @@ print_error(){
fi fi
} }
#pkg_check(){
# #WIP
# if [[ $(dpkg-query -f'${Status}' --show $PKG 2>/dev/null) = *\ installed ]]; then
# echo "WIP"
# else
# sudo apt-get -y install $PKG 2>/dev/null
# fi
#}
build_fw(){ build_fw(){
if [ -d $KLIPPER_DIR ]; then if [ -d $KLIPPER_DIR ]; then
cd $KLIPPER_DIR && make menuconfig cd $KLIPPER_DIR && make menuconfig

View File

@@ -155,9 +155,10 @@ dwc2_reverse_proxy_dialog(){
} }
dwc2_reverse_proxy(){ dwc2_reverse_proxy(){
if ! [[ $(dpkg-query -f'${Status}' --show nginx 2>/dev/null) = *\ installed ]]; then #check for dependencies
sudo apt-get install nginx -y dep=(avahi-daemon nginx)
fi dependency_check
#execute operations
cat ${HOME}/kiauh/resources/dwc2_nginx.cfg > ${HOME}/kiauh/resources/dwc2 cat ${HOME}/kiauh/resources/dwc2_nginx.cfg > ${HOME}/kiauh/resources/dwc2
sudo mv ${HOME}/kiauh/resources/dwc2 /etc/nginx/sites-available/dwc2 sudo mv ${HOME}/kiauh/resources/dwc2 /etc/nginx/sites-available/dwc2
if [ -e /etc/nginx/sites-enabled/default ]; then if [ -e /etc/nginx/sites-enabled/default ]; then

View File

@@ -3,10 +3,12 @@ mainsail_install_routine(){
if [ -d $KLIPPER_DIR ]; then if [ -d $KLIPPER_DIR ]; then
#check for dependencies #check for dependencies
dep=(wget curl unzip) dep=(wget curl unzip)
dep_check dependency_check
#execute operation #execute operation
#disable octoprint service if installed #disable octoprint service if installed
disable_octoprint_service if systemctl is-enabled octoprint.service -q 2>/dev/null; then
disable_octoprint_service
fi
disable_haproxy_lighttpd disable_haproxy_lighttpd
remove_haproxy_lighttpd remove_haproxy_lighttpd
install_moonraker install_moonraker