Skip to content

Instantly share code, notes, and snippets.

obazoud /
Created October 21, 2016 19:33 — forked from bortzmeyer/
Attack against Dyn from Free (France)
% check-soa -i OK: 2007130853 (22 ms)
	2001:500:90:1::34: ERROR: read udp [2001:500:90:1::34]:53: i/o timeout ERROR: read udp i/o timeout OK: 2007130853 (28 ms)
	2001:500:94:1::34: ERROR: read udp [2001:500:94:1::34]:53: i/o timeout
obazoud /
Created May 17, 2016 14:11 — forked from Dunedan/
Small bash script to get the lifecycle transitions of all buckets in an AWS account.
BUCKETS=$(aws --profile $AWS_PROFILE s3api list-buckets --query 'Buckets[*].Name' --output text)
echo -e "bucket name\tstatus of the transition\tprefix the transition applies to\tdays after which the transition applies\tto storage class\tdelete after days\tdescription"
for bucket in $BUCKETS; do
TRANSITION=$(aws --profile $AWS_PROFILE s3api get-bucket-lifecycle --bucket $bucket --query 'Rules[*][Status, Prefix, Transition.Days, Transition.StorageClass, Expiration.Days ID]' --output text 2> /dev/null)
if [ "$?" = "255" ]; then
obazoud / create_table.sql
Created April 8, 2016 15:26 — forked from marcocitus/create_table.sql
Scripts for loading Github events into Citus
CREATE TABLE github_events
event_id bigint,
event_type text,
event_public boolean,
repo_id bigint,
payload jsonb,
repo jsonb,
actor jsonb,
org jsonb,
obazoud / function.js
Last active August 29, 2015 14:25 — forked from vgeshel/function.js
AWS Lambda function for forwarding SNS notifications to Slack
console.log('Loading function');
const https = require('https');
const url = require('url');
// to get the slack hook url, go into slack admin and create a new "Incoming Webhook" integration
const slack_url = '';
const slack_req_opts = url.parse(slack_url);
slack_req_opts.method = 'POST';
slack_req_opts.headers = {'Content-Type': 'application/json'};
language: node_js
- '0.10'
- master
before_script: .travis/
script: echo -e " >>> Do something... \"grunt\" for example\n"
after_success: .travis/
obazoud / gist:9aa1d005ce619ccea5e8
Created March 18, 2015 15:32
Chef: Migrate role name with Knife
knife exec -E 'nodes.find("role:qwerty") { |node| new_run_list = { |element| (element == "role[qwerty]") ? "role[azerty]" : element }; node.run_list.reset!(new_run_list);; }'
- http://<%= node['gem_file']['host'] %>:<%= node['gem_file']['port'] %>/
* To get started:
* git clone
* cd algebird
* ./sbt algebird-core/console
* Let's get some data. Here is Alice in Wonderland, line by line
#!/usr/bin/env python
This module will bootstrap a machine using chef. The purpose of this
script is actually to work with AWS Auto Scaling Groups. The user data
for the Launch Configuration is set to download this script and then
run it. This is also stores the results in a private gist and sends
a message to logstash with the results.
obazoud / report.sql
Last active August 29, 2015 14:11
When a cookbook has been uploaded to chef server ?
-- su - opscode-pgsql
-- psql -d opscode_chef
v.major || '.' || v.minor || '.' || v.patch AS version,
FROM cookbooks AS c
JOIN cookbook_versions AS v
ON = v.cookbook_id