Skip to content

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 

Repository files navigation

upcheck

Is your site up? Check HTTP status, response time and SSL certificate expiry for any list of sites — straight from the terminal, in one color-coded glance. Zero dependencies, just Python.

Python License: MIT Dependencies

Why

I self-host my website on a Raspberry Pi, and the question "is it still up?" deserves a faster answer than opening a browser. upcheck pings all my sites in parallel and tells me three things I actually care about: is it reachable, how fast is it, and when does the SSL certificate expire — the one that always sneaks up on you.

It completes a little trilogy of terminal tools: pulse watches your machine, coinpeek watches the market, and upcheck watches your sites.

Install

git clone https://github.com/0iroN/upcheck.git
cd upcheck

That's it. No pip install — it only uses the Python standard library.

Usage

python upcheck.py osmandemir.net github.com   # check any sites (scheme optional)
python upcheck.py --certs mysite.com          # also show days until SSL expiry
python upcheck.py -f sites.txt                # read sites from a file
python upcheck.py -w 60 -f sites.txt          # live view, refreshing every 60s

The exit code is 0 only when every site is healthy, so it drops straight into cron or CI:

python upcheck.py -f sites.txt || notify-send "a site is down!"

Example

  upcheck  · 4 site(s) · 21:15:00

  ● github.com                            200     291 ms   cert 53d
  ● osmandemir.net                        200     196 ms   cert 71d
  ● example.com                           200     177 ms   cert 80d
  ● definitely-not-real-site-9482.net    DOWN         -  name not resolved

  3 up · 1 down

Healthy sites are green, client errors are yellow, server errors and unreachable sites are red. Certificates turn yellow under 30 days and red under 7.

Notes

  • Sites are checked in parallel (up to 8 at a time), so a long list still finishes fast.
  • A site file is one URL per line; blank lines and # comments are ignored.
  • --watch enforces a minimum 5-second interval to stay polite to your own servers.

License

MIT © Osman Demir

About

Is your site up? Check HTTP status, response time and SSL certificate expiry from the terminal. Zero dependencies.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages