Last active
January 20, 2016 19:48
-
-
Save eyenx/9fe1c7afc374adad0020 to your computer and use it in GitHub Desktop.
Test if let's encrypt certificate is about to expire and redeploy tutum stack to get a new one
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| test $(($(date "+%s" --date="$(openssl s_client -connect eyenx.ch:443 2>/dev/null <<<QUIT | openssl x509 -noout -enddate | cut -d= -f2)") - $(date "+%s"))) -lt 86400 && tutum stack redeploy eyenx-ch |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment