Skip to content

Instantly share code, notes, and snippets.

View calston's full-sized avatar

Colin Alston calston

View GitHub Profile
~# tracepath 196.216.242.2
1: vumi-gateway.za.prk-host.net 0.069ms pmtu 1500
1: 197.221.31.89 4.221ms
1: 197.221.31.89 4.204ms
2: 41.204.206.36 0.790ms asymm 3
3: 41.203.6.41 16.887ms asymm 5
4: ge8-0-0.gw1.cpt1.za.mtnbusiness.net 0.877ms asymm 5
5: 196.7.21.14 0.918ms
6: 196.7.21.3 1.053ms asymm 5
7: srp5-0-0.cr2.cpt1.za.mtnbusiness.net 187.935ms asymm 5
Currently vpnc-script is not directly configurable from configfiles.
However, a workaround is to use a "wrapper-script" like this, to
disable /etc/resolv.conf rewriting and setup a custom split-routing:
------------------------------
#!/bin/sh
# this effectively disables changes to /etc/resolv.conf
INTERNAL_IP4_DNS=
Notice: Finished catalog run in 20.59 seconds
Error: Could not send report: Error 400 on SERVER: Could not intern from pson: undefined method `from_pson' for Puppet::Transaction::Report:Class
Notice: There was an error sending the report.
Notice: This error is possibly caused by sending the report in a format the master can not handle.
Notice: A puppet master older than 3.2.2 can not handle pson reports.
Notice: Set report_serialization_format=yaml on the agent to send reports to older masters.
Notice: See http://links.puppetlabs.com/deprecate_yaml_on_network for more information.
# aptitude install puppet
The following packages will be upgraded:
puppet puppet-common{b}
2 packages upgraded, 0 newly installed, 0 to remove and 158 not upgraded.
Need to get 1 146 kB of archives. After unpacking 943 kB will be used.
The following packages have unmet dependencies:
puppetmaster-common : Depends: puppet-common (= 3.1.1-1puppetlabs1) but 3.3.0-1puppetlabs1 is to be installed.
puppet-common : Depends: ruby-rgen (>= 0.6.5) which is a virtual package.
open: 1291; closed: 83; defer: 1229; conflict: 1229 oThe following actions will resolve these dependencies:
@calston
calston / gist:6654546
Created September 21, 2013 21:46
Riakasaurus compat test
riakasaurus.test_crosscompat.test_basic
Tests
test_client ...
self.client.is_alive... [PASS]
self.client.ping... [FAIL]
self.client.stream_buckets... [FAIL]
self.client.bucket... [PASS]
self.client.get_keys... [FAIL]
self.client.get... [FAIL]
self.client.stream_keys... [FAIL]
#!/bin/bash
for i in *
do
w=`identify -format "%[fx:w]" "$i"`
if [ "$w" -gt "1280" ]; then
mogrify -resize 1280x1024 "$i"
fi
done
from twisted.internet import ssl, protocol
from twisted.protocols.tls import TLSMemoryBIOFactory
from txeap import proto_utils
class EAPTLSProtocol(protocol.Protocol):
def dataReceived(self, bytes):
print "Received:", repr(bytes)
serverFactory = protocol.ServerFactory()
if $nginx {
file { '/etc/munin/plugins/nginx_request':
ensure => present,
mode => '0755',
owner => root,
group => root,
source => 'puppet:///modules/munin/nginx_request',
notify => Service['munin-node']
}
}
Facter.add("nginx") do
setcode do
if File.exist? "/etc/nginx/nginx.conf"
true
else
false
end
end
end
@calston
calston / gist:5352673
Created April 10, 2013 07:56
Milestone assignees are semantically confusing
diff --git a/central/projects/models.py b/central/projects/models.py
index a094fca..e99c24d 100644
--- a/central/projects/models.py
+++ b/central/projects/models.py
@@ -130,7 +130,6 @@ class PlanMilestone(models.Model):
created_by_user = models.ForeignKey(User,
related_name='MilestoneCreatedBy')
plan = models.ForeignKey(Plan)
- assignee = models.ForeignKey(User)