Skip to content

Instantly share code, notes, and snippets.

View matthiassb's full-sized avatar
🎯
Focusing

Matthias Brooks matthiassb

🎯
Focusing
View GitHub Profile
@matthiassb
matthiassb / Purge_CloudWatchAlarms.py
Created February 24, 2020 04:59 — forked from jonathanwcrane/Purge_CloudWatchAlarms.py
Purge CloudWatch alarms for instances that no longer exist
#Step 1: Get a list of all alarms in INSUFFICIENT_DATA status
#Step 2: Get a list of all instances (stopped and started)
#Step 3: Find all alarms on instances that don't exist, and delete them
###################################################
#Step 1: Get alarms in INSUFFICENT_DATA state
###################################################
#The max that we can get per loop is 100; all alarms for nonexistent instances will be in
#INSUFFICIENT_DATA state so let's just go through those.
insuff_alarms = []
loops = 1
@matthiassb
matthiassb / SSLPoke.java
Last active August 29, 2015 14:13 — forked from 4ndrej/SSLPoke.java
import javax.net.ssl.SSLSocket;
import javax.net.ssl.SSLSocketFactory;
import java.io.*;
/** Establish a SSL connection to a host and port, writes a byte and
* prints the response. See
* http://confluence.atlassian.com/display/JIRA/Connecting+to+SSL+services
*/
public class SSLPoke {
public static void main(String[] args) {