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
# return the data bag object given an org and databag name | |
def get_bag(org, bag_name) | |
if ORGS[org] == nil | |
raise RuntimeError, "Bad org name provided" | |
else | |
bag = ORGS[org].databags[bag_name] | |
bag.kind_of? Mixlib::Authorization::Models::DataBag or raise RuntimeError, "Bad data bag name provided" | |
end |
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 | |
require 'rubygems' | |
require "bundler/setup" | |
$:.unshift(File.dirname(__FILE__) + '/../lib/') | |
require 'orgmapper' | |
require 'orgmapper/config' | |
config_file = ARGV.first |
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
def pp_cookbook(cb) | |
pp api.get "/cookbooks/#{cb}" | |
end | |
api.get('/cookbooks').keys.first(12).each do |cb| | |
thrds = Array.new | |
thrds << Thread.new { pp_cookbook(cb) } | |
thrds.each do |t| | |
t.join |
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
%% @private | |
handle_call({publish, Key, Message, Opts}, _From, | |
State = #bunnyc_state{channel=Channel, exchange=Exchange}) | |
when is_binary(Key), is_binary(Message) orelse ?is_message(Message), | |
is_list(Opts) -> | |
Resp = internal_publish(fun amqp_channel:call/3, | |
Channel, Exchange, Key, Message, Opts), | |
{reply, Resp, State}; | |
handle_call({get, NoAck}, _From, |
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 bash | |
# Author:: Paul Mooring (<[email protected]>) | |
# Author:: Steven Danna (<[email protected]>) | |
# Copyright:: Copyright (c) 2013 Opscode, Inc. | |
# License:: Apache License, Version 2.0 | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at |
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
# Author:: Guilhem Lettron (<[email protected]>) | |
# Cookbook Name:: webpi | |
# Recipe:: install-msi | |
# | |
# Copyright 2011, Opscode, Inc. | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at | |
# |
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
# | |
# Author:: Seth Chisamore (<[email protected]>) | |
# Cookbook Name:: webpi | |
# Provider:: product | |
# | |
# Copyright:: 2011, Opscode, Inc. | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at |
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
# | |
# Author:: Seth Chisamore (<[email protected]>) | |
# Cookbook Name:: webpi | |
# Provider:: product | |
# | |
# Copyright:: 2011, Opscode, Inc. | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at |
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
[2013-02-21T22:42:05+00:00] INFO: Loading cookbooks [bluepill, build-essential, chef-client, ntp, rsyslog, runit] | |
which: no chef-server in (/sbin:/bin:/usr/sbin:/usr/bin:/opt/chef/embedded/bin:/opt/chef/embedded/bin:/usr/local/sbin:/usr/local/bin) | |
which: no chef-server in (/sbin:/bin:/usr/sbin:/usr/bin:/opt/chef/embedded/bin:/opt/chef/embedded/bin:/usr/local/sbin:/usr/local/bin) | |
================================================================================ | |
Recipe Compile Error in /var/chef/cache/cookbooks/chef-client/recipes/default.rb | |
================================================================================ | |
Chef::Exceptions::CookbookNotFound | |
---------------------------------- |
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
[pmooring@jenkins ~]$ valgrind --tool=massif --depth=1 --trace-children=yes knife -v && ms_print massif.out* | |
==16710== Massif, a heap profiler | |
==16710== Copyright (C) 2003-2010, and GNU GPL'd, by Nicholas Nethercote | |
==16710== Using Valgrind-3.6.0 and LibVEX; rerun with -h for copyright info | |
==16710== Command: /usr/bin/knife -v | |
==16710== | |
Chef: 11.2.0 | |
==16710== | |
-------------------------------------------------------------------------------- | |
Command: /usr/bin/knife -v |