mynode/rootfs/standard/usr/bin/mynode_stop_critical_services.sh

28 lines
569 B
Bash
Raw Normal View History

2019-12-19 03:45:44 +00:00
#!/bin/bash
2020-05-09 17:23:47 +00:00
# Message
echo "Stopping myNode services..."
2020-04-23 02:59:37 +00:00
# Mark we are shutting down
touch /tmp/shutting_down
2019-12-19 03:45:44 +00:00
# Stop additional services
2020-10-30 03:19:07 +00:00
systemctl stop glances lndhub netdata rtl webssh2 whirlpool dojo
systemctl stop btcpayserver btc_rpc_explorer specter caravan lnbits
2020-11-08 21:33:25 +00:00
systemctl stop thunderhub mempoolspace
2019-12-19 03:45:44 +00:00
# Manually stop services (backup)
if [ "$(systemctl is-active docker)" = "active" ]; then
/mnt/hdd/mynode/dojo/docker/my-dojo/dojo.sh stop || true
fi
2019-12-19 03:45:44 +00:00
# Stop core services
2020-10-30 03:19:07 +00:00
systemctl stop electrs loopd lnd quicksync bitcoind
2019-12-19 03:45:44 +00:00
2020-10-30 03:19:07 +00:00
# Sync filesystem
sync