Skip to content

Instantly share code, notes, and snippets.

View ocxo's full-sized avatar
💆‍♂️
domakesaythink

ocxo ocxo

💆‍♂️
domakesaythink
  • Vacant
View GitHub Profile
➜ cookbook-teamcity git:(master) ✗ vagrant provision
WARNING: Could not load IOV methods. Check your GSSAPI C library for an update
WARNING: Could not load AEAD methods. Check your GSSAPI C library for an update
[Berkshelf] uploading cookbooks to 'https://api.opscode.com/organizations/my_org'
[Berkshelf] Using cookbook-teamcity (0.0.1) at path: '/Users/Adam/src/cookbook-teamcity'
[Berkshelf] Using apt (1.5.0)
[Berkshelf] Uploading cookbook-teamcity (0.0.1) to: 'https://api.opscode.com/organizations/my_org'
[Berkshelf] Uploading apt (1.5.0) to: 'https://api.opscode.com/organizations/my_org'
[default] Running provisioner: Vagrant::Provisioners::ChefClient...
C:\opscode\chef\bin\chef-client.bat
[default] Destroying VM and associated drives...
/Users/Adam/.rbenv/versions/1.9.3-p286/lib/ruby/gems/1.9.1/gems/vagrant-windows-0.1.1/lib/vagrant-windows/guest/windows.rb:64:in `configure_networks': undefined method `read_mac_addresses' for #<Vagrant::Driver::VirtualBox_4_2:0x007fd36ae91ca0> (NoMethodError)
from /Users/Adam/.rbenv/versions/1.9.3-p286/lib/ruby/gems/1.9.1/gems/vagrant-1.0.5/lib/vagrant/action/vm/network.rb:72:in `call'
from /Users/Adam/.rbenv/versions/1.9.3-p286/lib/ruby/gems/1.9.1/gems/vagrant-1.0.5/lib/vagrant/action/warden.rb:33:in `call'
from /Users/Adam/.rbenv/versions/1.9.3-p286/lib/ruby/gems/1.9.1/gems/vagrant-1.0.5/lib/vagrant/action/vm/clear_network_interfaces.rb:26:in `call'
from /Users/Adam/.rbenv/versions/1.9.3-p286/lib/ruby/gems/1.9.1/gems/vagrant-1.0.5/lib/vagrant/action/warden.rb:33:in `call'
from /Users/Adam/.rbenv/versions/1.9.3-p286/lib/ruby/gems/1.9.1/gems/vagrant-1.0.5/lib/vagrant/action/vm/host_name.rb:10:in `call'
from /Users/Adam/.rbenv/versions/1.9.3-p286/lib/ruby
current_dir = File.dirname(__FILE__)
log_level :info
log_location STDOUT
node_name "articulate"
client_key "#{ENV['HOME']}/.chef/articulate.pem"
validation_client_name "articulate-validator"
validation_key "#{ENV['HOME']}/.chef/articulate-validator.pem"
chef_server_url "https://api.opscode.com/organizations/articulate"
cache_type 'BasicFile'
cache_options( :path => "#{ENV['HOME']}/.chef/checksums" )
#!/usr/bin/env ruby
# encoding: UTF-8
require 'iconv'
def read_dir(dir, opts={})
Dir.glob("#{dir}/*").each_with_object({}) do |f, h|
if File.file?(f)
File.open(f, "r:UTF-8") do |rf|
puts rf.path
@ocxo
ocxo / replace.rb
Last active December 10, 2015 21:38
recursively replace similar lines of html with ssi and remove bogus tags given a nested directory
#!/usr/bin/env ruby
# encoding: UTF-8
#usage: `ruby replace.rb /path/to/target/directory`
require 'iconv'
def read_dir(dir, opts={})
Dir.glob("#{dir}/*").each_with_object({}) do |f, h|
if File.file?(f)
current_dir = File.dirname(__FILE__)
log_level :info
log_location STDOUT
node_name "fromonesrc"
client_key "#{ENV['HOME']}/.chef/fromonesrc.pem"
validation_client_name "articulate-validator"
validation_key "#{ENV['HOME']}/.chef/articulate-validator.pem"
chef_server_url "https://api.opscode.com/organizations/articulate"
cache_type 'BasicFile'
cache_options( :path => "#{ENV['HOME']}/.chef/checksums" )
require 'rubygems'
require 'open-uri'
require 'fileutils'
require 'nokogiri'
require 'date'
require 'json'
require 'uri'
require 'jekyll'
module Jekyll
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDyAmMRbftmYBy7zl9SzCwbDZ6+XKtLDf2zvUmTJQu4yr9uF4j7rVcgpJRTTn7rYR4JYR62rtnHVOolgE7ZFnYK4NS6M5Isu9JrgsevD/eESdJwOooFxMxWPXcsm2+XSy7eGeCQlDsF54TupRCgPErslC8uRK+yl8iEDGtj9UNO5HQfe/IRv2YjVRAczxK+KVercz7GLRmRSkTeRXikrkdkXeZ1+KHmilD5pJ74rICXZKjoOW52CfvXQymY+86T6pBh2KQ4AkJWmKX2LJm5e3Tyh0zewKEGB1hfCBBFFLi0BW4mzQ3cUBBHsHEWZ5XmqSvv4rKb9jSV8Cu/dKOd+ntV [email protected]
@ocxo
ocxo / pushy.rb
Last active December 11, 2015 03:48
require 'dropbox-api'
require "yaml"
config = YAML.load_file "dropbox.yml"
Dropbox::API::Config.app_key = config['app_key']
Dropbox::API::Config.app_secret = config['app_secret']
Dropbox::API::Config.mode = config['mode']
client = Dropbox::API::Client.new \