Skip to content

Instantly share code, notes, and snippets.

View danishbacker's full-sized avatar

Danish Backer danishbacker

View GitHub Profile
@TomRyan-321
TomRyan-321 / security-group-cleanup.py
Last active October 10, 2022 09:38 — forked from lingmann/security-group-cleanup.py
Security Group Cleanup using boto3 with RDS check fixed
#!/usr/bin/env python
import boto3
import argparse
def lookup_by_id(sgid):
sg = ec2.get_all_security_groups(group_ids=sgid)
return sg[0].name
@atishgoswami
atishgoswami / Cakephp::breadCrumbs
Last active December 17, 2015 00:29
Cakephp Dynamic BreadCrumbs
<?php
$action = $this->params->action;
if ($this->params->admin) {
$action = str_replace('admin_', '', $action);
}
if ($action == 'index') {
$options = array('class' => 'current');
} else {
@oodavid
oodavid / README.md
Created March 26, 2012 17:05
Backup MySQL to Amazon S3

Backup MySQL to Amazon S3

This is a simple way to backup your MySQL tables to Amazon S3 for a nightly backup - this is all to be done on your server :-)

Sister Document - Restore MySQL from Amazon S3 - read that next

1 - Install s3cmd

this is for Centos 5.6, see http://s3tools.org/repositories for other systems like ubuntu etc