Skip to content

Instantly share code, notes, and snippets.

% dpkg -L libpcap0.8 | grep libpcap.so
/usr/lib/x86_64-linux-gnu/libpcap.so.1.1.1
/usr/lib/x86_64-linux-gnu/libpcap.so.0.8
  1. Install XCode

  2. Install Command Line Tools from XCode Preferences

  3. Install Homebrew

  4. Install rvm or rbenv

  5. Install Matterhorn dependencies within Homebrew

#!/bin/bash
if ! [ $3 ] ; then
echo "$0 <SOURCE POOL/DATASET> <TARGET_HOST> <TARGET POOL/DATASET>"
exit 1
fi
SRC=$1
TARGET_HOST=$2
DST=$3
@mikeyk
mikeyk / watch_wal-e.py
Created January 16, 2013 20:24
Watch_wal-e script
#! /usr/bin/env python
from boto.ses.connection import SESConnection
import os
import sys
import subprocess
import socket
TMPFILE = '/var/run/postgresql/last-wal-archive-error-file.tmp'
if __name__ == '__main__':
@SlexAxton
SlexAxton / .zshrc
Last active November 6, 2025 22:31
My gif workflow
gifify() {
if [[ -n "$1" ]]; then
if [[ $2 == '--good' ]]; then
ffmpeg -i $1 -r 10 -vcodec png out-static-%05d.png
time convert -verbose +dither -layers Optimize -resize 600x600\> out-static*.png GIF:- | gifsicle --colors 128 --delay=5 --loop --optimize=3 --multifile - > $1.gif
rm out-static*.png
else
ffmpeg -i $1 -s 600x400 -pix_fmt rgb24 -r 10 -f gif - | gifsicle --optimize=3 --delay=3 > $1.gif
fi
else
@mbklein
mbklein / gist:5164111
Created March 14, 2013 18:52
Turning stock matterhorn into avalon matterhorn
Drop into lib/matterhorn:
https://github.com/avalonmediasystem/avalon-felix/raw/1.4.x/lib/matterhorn/matterhorn-ingest-service-impl-1.4-SNAPSHOT.jar
https://github.com/avalonmediasystem/avalon-felix/raw/1.4.x/lib/matterhorn/matterhorn-distribution-service-hls-1.4-SNAPSHOT.jar
https://github.com/avalonmediasystem/avalon-felix/raw/1.4.x/lib/matterhorn/matterhorn-distribution-service-streaming-1.4-SNAPSHOT.jar
https://github.com/avalonmediasystem/avalon-felix/raw/1.4.x/lib/matterhorn/matterhorn-workflow-notifier-avalon-1.4-SNAPSHOT.jar
Drop into etc/encoding:
https://raw.github.com/avalonmediasystem/avalon-felix/1.4.x/etc/encoding/avalon.properties
@jordelver
jordelver / gist:5806460
Created June 18, 2013 15:41
Sharing files using netcat

Sharing files using netcat

The receiver

nc -l 5566 > data-dump.sql

Listen on port 5566 and redirect output to data-dump.sql

The sender

@corny
corny / git.cap
Created November 14, 2013 01:31
Capistrano 3 with Git Submodules
# Save this file as lib/capistrano/tasks/git.cap
namespace :git do
desc 'Copy repo to releases'
task create_release: :'git:update' do
on roles(:all) do
with fetch(:git_environmental_variables) do
within repo_path do
execute :git, :clone, '-b', fetch(:branch), '--recursive', '.', release_path
end
mount_map = Hash[
`mount`.split(/\n/).collect { |l|
(loc, mount, type) = l.scan(/^(.+) on (.+) type (\S+) /).flatten
if loc =~ /:\//
loc = "#{type}://#{loc.sub(/:\//,'/')}"
[mount, loc]
end
}.compact
]
#requires -Version 3.0
<#
.SYNOPSIS
My Veeam Report is a flexible reporting script for Veeam Backup and
Replication.
.DESCRIPTION
My Veeam Report is a flexible reporting script for Veeam Backup and
Replication. This report can be customized to report on Backup, Replication,