Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/yurenchen000/disk_notify

send notify if disk space low
https://github.com/yurenchen000/disk_notify

disk-space notification notify

Last synced: 29 days ago
JSON representation

send notify if disk space low

Awesome Lists containing this project

README

        

disk notify
===========

send notify if disk avail space low

[README δΈ­ζ–‡](README_CN.md)

only-bash.jpg

- Lightweight: only bash, df, curl
- Focus: only notify alert if space low
- Accuracy: partition specified threshold
- Reliable: multiple push channels


## πŸ› οΈ Settings
it can monit multi mountpoint with specified thresholds
by bash associative array. (key-value pairs)

```sh
declare -A mount_thresholds=(
["/"]="5120" # 5 GB in MB
["/tmp"]="1024" # 1 GB in MB
)
```


supported notify backends
- telegram bot
- feishu bot
- wework bot
- dingtalk bot
- pushplus
- wxpusher
- serverchan


logs
- disk_log=disk_hist.log //disk space log
- send_log=send_hist.log //send noitfy log


notify frequency
- push_delay=30 //push interval (will adjusted dynamically)


check frequency
- save_interval=3600 // 1 hour
- check_interval=300 // 5 min


## πŸš€ Usage
download from https://github.com/yurenchen000/disk_notify/releases/latest
and uncompress it.

// edit conf base on example
```
cp -pv _disk_notify_global.example _disk_notify_global
// modify the conf according to your needs
```

conf file
- ./_disk_notify_global
- ~/.config/_disk_notify


// run in background
```
nohup ./disk_notify.sh &> disk_notify.out &
```