Skip to content

Instantly share code, notes, and snippets.

View blkperl's full-sized avatar

William Van Hevelingen blkperl

View GitHub Profile
#!/bin/sh
RUBYOPT='-W0'
export RUBYOPT
su - postgres <<ENDOFSU
psql puppetdb <<ENDOFPS
delete from catalogs where hash in ( select catalog from catalog_resources where title like '%$1%' );
delete from certname_facts_metadata where certname = '$1';
delete from certname_facts where certname = '$1';
@blkperl
blkperl / gist:6749938
Created September 29, 2013 06:45
gource to video oneliner
sudo apt-get install libx264-123 libavcodec-extra-53
gource -720x480 --hide filenames --logo cat_logo.png -s .5 -o - | ffmpeg -y -r 60 -f image2pipe -vcodec ppm -i - -vcodec libx264 -crf 1 -threads 2 -bf 0 gource.mp4
build: clean
mkdir build
pdflatex -output-directory build exercise1.tex
mv build/exercise1.pdf ~/public_html
chmod 755 ~/public_html/exercise1.pdf
clean:
rm -rf build
include collectd
include collectd::plugin::tail
collectd::plugin::tail::fragment { '/var/log/exim4/mainlog':
instance => "exim",
matches => [
{
regex => "S=([1-9][0-9]*)",
dstype => "CounterAdd",
type => "ipt_bytes",
<VirtualHost 131.252.208.65:80>
ServerName metrics.cat.pdx.edu
DocumentRoot /disk/trump/leonardo
WSGIDaemonProcess leonardo user=leonardo group=leonardo threads=5
WSGIScriptAlias / /disk/trump/leonardo/leonardo/leonardo.wsgi
ErrorLog /var/log/apache2/metrics-error.log
LogLevel warn
CustomLog /var/log/apache2/metrics-access.log combined
$ getfacl .
# file: .
# owner: wvan
# group: cs333
user::rwx
group::---
other::---
@blkperl
blkperl / vagrantfile.rb
Created February 19, 2014 08:03
solaris11 with multiple disks vagrant file
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.define "sunosfiler" do |v|
@blkperl
blkperl / Vagrantfile
Last active February 23, 2016 22:44
solaris11 with multiple disks vagrant file
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
diskroot = "/home/#{ENV['USER']}/VirtualBox\ VMs/"
@blkperl
blkperl / gist:9821825
Created March 27, 2014 23:51
future parser $:fqdn puppet apply
fab02:~# puppet --version
3.4.3
fab02:~# cat test.pp
class bar {
notify { $:fqdn: }
}