manifest / integrations / mainwp-monitoring-notify
MainWP Monitoring Notify
The MainWP Monitoring Notify extension allows you to send notifications via Line Notify when your site goes offline.
by J7 · github.com/j7-dev/mainwp-monitoring-notify · website
★ 4stars
36release downloads
≈10active sites
0forks
Install
The author publishes release zips, so WP-CLI can install straight from GitHub:
wp plugin install https://github.com/j7-dev/mainwp-monitoring-notify/releases/download/v1.3.0/mainwp-monitoring-notify.zipFrom the readme
MainWP Monitoring Notify | 讓 MainWP 監控更及時 :
一句話講完 MainWP Monitoring Notify :
MainWP Monitoring Notify 是一個 WordPress 套件,依賴 MainWP 來監控網站運作狀態,並透過 LINE Notify 來通知你。
預覽
⚡ 主要功能
使用 LINE NOTIFY 通知
如果你覺得通知太頻繁,可以設定,只有網站斷線時才通知
1. 如何申請 LINE Notify Token
1-1. 請先前往 LINE Notify 並登入你的 LINE
1-2. 點擊 Generate token 然後選擇想要通知的聊天室
1-3. 複製 token 然後貼到這邊保存
1-4. 最後,邀請 LINE Notify 到你第二步選擇的聊天室就完成了🎉🎉🎉
2. 常見 Q & A
2-1. 多久檢查一次?
看你 Sites Monitoring ,中的設置是多久,最短可以 每 5 分鐘 檢查一次
2-2. 運作原理是什麼?
是使用 WP CRON 搭配 MainWP 本身的 hook 做成
⚠️ WP CRON 必須是 有人造訪網站時才會觸發,如果您的網站流量本身並不高,推薦使用 主機本身提供的 crontab 來實現,詳細可參考 官方文章 或 這篇文章
也因為如此,斷線的檢查推波通知 並非準確的 5 分鐘
2-3. [進階] 設定準確的定時任務 - 使用 crontab
如果你的主機商允許你設定 crontab 那麼,你可以透過 crontab 實現準確的定時任務,也可以參考此 crontab 教學
2-3-1. 取消這個外掛的 WP CRON
在你主題底下的 functions.php 輸入
addfilter( 'mainwpmonitoringnotifywpcronenabled' , 'returnfalse', 100, 1 );
2-3-2. ssh 伺服器後輸入 crontab -e ,開啟 crontab 設定
⚠️ 請確保你的伺服器上可以執行 php 指令
⚠️ 下方的 {{PATH}} 請自行替換此網站的檔案路徑,例: /var/www/html/MYSITE
例: 每分鐘執行一次:
php {{PATH}}/wp-content/plugins/mainwp-monitoring-notify/cron/exec.php /dev/null 2&1
例: 每 5 分鐘執行一次:
/5 php {{PATH}}/wp-content/plugins/mainwp-monitoring-notify/cron/exec.p
Read the full README on GitHub →
Releases
| Tag | Published | Asset | Downloads |
|---|---|---|---|
| v1.3.0 | Feb 18, 2024 | mainwp-monitoring-notify.zip | 11 |
| v1.2.2 | Feb 18, 2024 | mainwp-monitoring-notify.zip | 6 |
| v1.2.1 | Feb 18, 2024 | mainwp-monitoring-notify.zip | 3 |
| v1.2.0 | Feb 18, 2024 | mainwp-monitoring-notify.zip | 4 |
| v1.1.1 | Feb 16, 2024 | mainwp-monitoring-notify.zip | 6 |
| v1.0.0 | May 26, 2023 | mainwp-monitoring-notify-v1.0.0.zip | 6 |
Active-site estimate ≈10 comes from the median of recent superseded releases. Method.