Application Monitor
The script is unofficial and not supported by Ultra.cc staff.
The Application monitor script can be used to automatically restart applications if they go offline unexpectedly. The activity can be logged to a log file or be sent to Discord.
Installation
Before you can proceed with installing the Application monitor script, Python needs to be version 3.6 or above.
Upgrade Python
RunConnect to your Ultra.cc slot via SSH, see guide here.- Once connected, execute the following
command via SSH:command:
bash <(wget -qO- https://scripts.usbx.me/main/Utility%20Scripts/app-monitor-install.util/Python-Installer/main.sh)
YouTypewill be given a choiceconfirm
tochoose between storing logs and receiving discord notifications. In that case that you plan to receive discord notifications, keep a discord webhook URL ready to be usedproceed with thescript.installation.TheNext,scriptpickwillaaskPython version above 3.6 or type4
foralatestlistversion- Press
applications that you wishENTER tomonitor.confirm. Example:When the installation has finished, execute the following command:
Pleasesource enter all applications you want to monitor with a single space in between(for example sonarr radarr lidarr):~/.profile
EnterPython updated to version 3.6 or above, you can proceed theapplicationinstallation.namesInstall
withApplicationa space between each one and then hitEnter.
With
Log Location
Monitor
For users that are storing logs, they are atExecute the followinglocations:
Torrent Client Logs
~/scripts/app_monitor/torrent_clients.log
Docker Application Logs
~/scripts/app_monitor/docker_apps.log
Uninstallation
Run the following command via SSH:
bash <(wget -qO- https://scripts.usbx.me/main/Utility%20Scripts/app-monitor-install.util/All_app_monitor/app_monitor_installer.sh)
SelectTypeconfirm
to proceed with the installation.- Next, you will be presented with three options:
Please choose option from below if you want notification on discord or info as a log file on your service
1. Store Applications status on your service at {~/script/app_monitor}
2. To get application status on your Discord(You need Discord Webhook for it)
3. To uninstall the script.
Please select option 1 or 2:
OPTION 1:
- Press
1
whentopromotedstore application status in a log file on your service. PressENTER
to confirm. - Type the application names you want to monitor, separated with single spaces:
radarr sonarr prowlarr
etc. - Press
ENTER
to confirm.
OPTION 2:
- Press
2
to push application status notifications to Discord via webhook. PressENTER
to confirm. - Paste your Discord webhook URL.
- Press
ENTER
to confirm.
Uninstallation
- Execute the following command:
bash <(wget -qO- https://scripts.usbx.me/util/All_app_monitor/app_monitor_installer.sh)
- Type
confirm
to proceed with the installation. - Next, you will be presented with three options:
- Press
3
to uninstall script. PressENTER
to confirm.
The script will ask you to confirm uninstallation.the uninstallation with YES or NO.
- Press
1
for uninstall. PressENTER
to confirm.
Log WeLocation
- For users who are
workingstoringonlogs,atheyscriptcanthatbeaims to improve the existing one's functionality. All feedback is welcomedfound athttps:these locations:
-
Torrent Client Logs:
~/
/feedback.ultra.ccscripts/app_monitor/torrent_clients.log -
Docker Application Logs:
~/scripts/app_monitor/docker_apps.log
Caveats
1)1. Do not uninstall applications that are being monitored by the Application Monitor script.
script
- You should only monitor applications that you do not plan to uninstall. OR
Setset up the script again before uninstalling a monitored application.
2)2. An issue that may occur with manual upgrades of docker applications.
applications
- The script checks all applications periodically and either restarts or upgrades them.
In that case thatIf you upgrade an application manually, it will be down for a certain amount of time. If the script happens to runit's checkwhen the application is down due to your manual upgrade action, the script will queue another upgrade. This will result in your application upgrading twice, it's not a majorissueissue, but it's not ideal either.