Skip to content

Instantly share code, notes, and snippets.

@lucabusin
lucabusin / rd-clean.sh
Last active February 5, 2021 22:07
Shell script to purge Rundeck execution history (extended from @unicolet's script https://gist.github.com/unicolet/af648a97163ce6b44645)
#!/bin/sh
# keep last few executions for each job
KEEP=100
# db connection params
HOST=YOURDBHOST
PORT=YOURDBPORT
USERNAME=YOURDBUSERNAME
PASSWORD=YOURDBPASSWORD
@jbsmith86
jbsmith86 / cert_vaildation
Last active April 18, 2018 18:30
This script returns the number of days left for validity of the certificate of a given url. Supports wildcard certs and SNI. Useful for monitoring.
#!/usr/bin/env ruby
require "optparse"
require "socket"
require "openssl"
require "time"
options = {
'port' => 443
}