Skip to content

Instantly share code, notes, and snippets.

@labfruits
Last active February 16, 2018 20:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save labfruits/611f439c9c07c8bd261d957afa127fe7 to your computer and use it in GitHub Desktop.
Save labfruits/611f439c9c07c8bd261d957afa127fe7 to your computer and use it in GitHub Desktop.
periodically chert check based on ssl-cert-check
#!/usr/bin/env bash
SH=$(readlink -f "${0}")
SH_PATH=$(dirname "${SH}")
CERT_DIR="${SH_PATH}/certs/*"
EXP_DAYS=60
SENDER="certs@foo.bar.com"
SEND_TO="root@foo.bar.com"
ssl-cert-check -a -d "${CERT_DIR}/*.crt" -q -x ${EXP_DAYS} -E ${SENDER} -e ${SEND_TO}
exit $?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment