Skip to content

Instantly share code, notes, and snippets.

@morganchristiansson
morganchristiansson / extract-123-reg-zonefile.js
Created March 15, 2017 13:30 — forked from biinari/extract-123-reg-zonefile.js
Script to extract the DNS entries from 123-reg advanced dns page
var table = document.getElementsByClassName('advanced_dns')[0];
var rows = table.getElementsByTagName('tr');
var i, len, row;
var hostname, type, priority, ttl, destination;
var output = '';
output += '$TTL 600\n'; // start with default TTL
// skip header and last two rows (add new entry, delete all entries)
for (i = 1, len = rows.length - 2; i < len; i++) {
@trilitheus
trilitheus / graphite wrapper attributes.rb
Last active August 29, 2015 14:02
graphite storage schema
override['graphite']['storage_schemas'] = [
{
'name' => 'chef_reporting',
'pattern' => 'chef.*',
'retentions' => '30m:2y'
},
{
'name' => '2min_interval',
'pattern' => '.*\.2m\..*',
'retentions' => '2m:30d,30m:1y'
@dysinger
dysinger / docker-ruby-fpm.sh
Last active August 29, 2015 13:56
Stop using rbenv & rvm on servers. plz. kthnx.
cat > Dockerfile <<\EOF
FROM ubuntu:12.04
RUN apt-get update
RUN apt-get install -y ruby1.9.3 build-essential \
libc6-dev libffi-dev libgdbm-dev libncurses5-dev \
libreadline-dev libssl-dev libyaml-dev zlib1g-dev
RUN gem install fpm --bindir=/usr/bin --no-rdoc --no-ri
RUN apt-get install -y curl
RUN curl ftp://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.3-p484.tar.gz|tar oxzC /tmp
WORKDIR /tmp/ruby-1.9.3-p484