Skip to content

Instantly share code, notes, and snippets.

View blkperl's full-sized avatar

William Van Hevelingen blkperl

View GitHub Profile
<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
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",
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
@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
#!/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';
class cecs::role::openstack::compute {
# assumes that eth0 is the public interface
$public_interface = 'eth0'
# assumes that eth1 is the interface that will be used for the vm network
# this configuration assumes this interface is active but does not have an
# ip address allocated to it.
$private_interface = 'br100'
$floating_network_range = '192.168.101.64/28'
class cecs::role::openstack::swift_proxy {
class { '::openstack::swift::proxy':
swift_user_password => hiera('swift_user_password'),
keystone_host => 'dagger.cat.pdx.edu',
memcached => true,
swift_memcache_servers => ['127.0.0.1:11211'],
memcached_listen_ip => '127.0.0.1'
}
@blkperl
blkperl / all.pp
Last active December 20, 2015 20:08
openstack::all
class cecs::role::openstack::all {
# assumes that eth0 is the public interface
$public_interface = 'eth0'
# assumes that eth1 is the interface that will be used for the vm network
# this configuration assumes this interface is active but does not have an
# ip address allocated to it.
$private_interface = 'br100'
$floating_network_range = '192.168.101.64/28'
@blkperl
blkperl / gist:5101611
Last active December 14, 2015 14:38
Parallel pg_dump Patch Testing