This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Forked from user dirk; changed to drop the should_render boolean arg and | |
# replace it with a separate method, cache_and_render | |
class ApplicationController < ActionController::Base | |
# Other random stuff. | |
protected | |
def cache_and_render(key, opts = {}) | |
cached = cache(key, opts) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
=pod | |
slavepush.pl | |
Author: Ted Behling <[email protected]> | |
Copyright 2010 Hargray Communications | |
See license below |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
# This Ruby script will extract data from a Basecamp "backup" XML file and import | |
# it into Redmine. | |
# | |
# You must install the Nokogiri gem, which is an XML parser: sudo gem install nokogiri | |
# | |
# This script is a "code generator", in that it writes a new Ruby script to STDOUT. | |
# This script contains invocations of Redmine's ActiveRecord models. The resulting | |
# "import script" can be edited before being executed, if desired. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Configuration files for connecting Fedora Linux to Amazon Virtual Private Cloud | |
===== | |
This Gist contains the config files that I have used to successfully connect Fedora 15 (as the "Customer Gateway" in AWS terms) to Amazon's Virtual Private Cloud VPN. These files were pulled from a working environment but I have obfuscated the public IP addresses involved. I have found IPsec to be one of the more complicated technologies to get running successfully, as there are a lot of moving parts and subtle configuration settings involved. I post this here in the hope it might be of some help to others. | |
I received a lot of help from this blog post: http://openfoo.org/blog/amazon_vpc_with_linux.html . Besides IPsec, VPC requires BGP; I used basically the same config files shown there. They use Ubuntu, and I am running Fedora, but the upstream software packages used are the same. They call for installing a couple Ubuntu packages; the equivalent on Fedora 15 is: | |
yum install quagga ipsec-tools | |
You can read about |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/ruby | |
require 'net/telnet' | |
class RokuClient | |
attr_accessor :connection | |
def initialize(ip, port = 8080) | |
@connection = Net::Telnet::new( | |
"Host" => ip, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"encoding/hex" | |
"github.com/keybase/go-triplesec" | |
"os" | |
"runtime" | |
"strconv" | |
"sync" | |
// "time" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Keybase proof | |
I hereby claim: | |
* I am tedb on github. | |
* I am tedb (https://keybase.io/tedb) on keybase. | |
* I have a public key ASCNrOZSUvFGnd5X7CHPSPIVdCvM6xe8BGBi0KVHOAllswo | |
To claim this, I am signing this object: |