Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cartermckinnon/url-monitor
Monitors URLs for a pattern, alerting by SMS.
https://github.com/cartermckinnon/url-monitor
Last synced: 18 days ago
JSON representation
Monitors URLs for a pattern, alerting by SMS.
- Host: GitHub
- URL: https://github.com/cartermckinnon/url-monitor
- Owner: cartermckinnon
- Created: 2021-01-24T23:13:48.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2021-02-07T10:29:04.000Z (almost 4 years ago)
- Last Synced: 2024-07-22T05:45:38.137Z (4 months ago)
- Language: Go
- Size: 9.77 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# URL Monitor
Monitors URLs for a pattern, alerting by SMS.
## Build
```sh
go build
```## Configure
Modify `configuration.yaml` as necessary.
1. **Twilio**. Add your Twilio account SID, auth token, and the *from* and *to* phone numbers for SMS alerts.
2. **URLs**. Add the URLs to monitor, with a helpful description which will be included in the SMS alert. Supported alert conditions (`alertIf`) are `Match`, `NoMatch`, and `Never`. Patterns are regular expressions supported by golang's `regexp` package.## Run
By default, `configuration.yaml` will be used.
```sh
./url-monitor
```## Usage
```
url-monitor - Monitors URLs for patterns, and alerts by SMS.Flags:
--version Displays the program version string.
-h --help Displays help with available flag, subcommand, and positional value parameters.
-c --configuration-file YAML configuration file defining URLs to monitor (default: configuration.yaml)
```## Example alert
For the URL configuration:
```yaml
- description: Google
url: https://google.com
pattern: google
alertIf: Match
```
You'll receive an SMS message that looks like:
```
url-monitor: alert triggered for Google. URL: https://google.com
```