Skip to content

Instantly share code, notes, and snippets.

View scotthain's full-sized avatar

Scott Hain scotthain

View GitHub Profile
@scotthain
scotthain / gist:8677234
Created January 28, 2014 21:49
example of FC006 failure on mode with array
files = [ ["file01", "755"],
["file02", "755"]
]
# Fails
files.each do |file_array|
cookbook_file "/tmp/#{file_array[0]}" do
backup false
source file_array[0]
owner "root"
@scotthain
scotthain / code snippet
Last active August 29, 2015 13:58
parameterized remote build error
Line 712:
if ( response.toString().isEmpty() ) {
listener.getLogger().println("Remote Jenkins server returned empty response to trigger.");
return null;
} else {
System.out.println("Output: " + response.toString());
responseObject = (JSONObject) JSONSerializer.toJSON(response.toString());
}
@scotthain
scotthain / gist:ca0f578a483cd14779dd
Created February 11, 2015 20:42
ipmitool -I lanplus -P <Password> -C1 -H <IP> sol activate -vvv
IPMI LAN host <IP> port 623
>> Sending IPMI command payload
>> netfn : 0x06
>> command : 0x38
>> data : 0x8e 0x04
BUILDING A v1.5 COMMAND
>> IPMI Request Session Header
>> Authtype : NONE
@scotthain
scotthain / gist:6d2d5c6dd93e3a498ed7
Created May 14, 2015 22:04
kimchi systemctl failure
[scott@powerglove kimchi]$ ./autogen.sh --system
configure.ac:41: installing 'build-aux/config.guess'
configure.ac:41: installing 'build-aux/config.sub'
configure.ac:35: installing 'build-aux/install-sh'
configure.ac:35: installing 'build-aux/missing'
src/kimchi/Makefile.am:22: installing 'build-aux/py-compile'
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
@scotthain
scotthain / diagnose
Last active August 29, 2015 14:23
winders
---
timestamp: 2015-06-18 21:23:12 UTC
kitchen_version: 1.4.1
instances:
default-centos-71:
platform:
os_type: unix
shell_type: bourne
state_file: {}
driver:
[Builder: opscode-chef-mover] I | Build opscode-chef-mover: 644.7252s
The following shell command exited with status 2:
$ CFLAGS=-I/opt/opscode/embedded/include CPPFLAGS=-I/opt/opscode/embedded/include CXXFLAGS=-I/opt/opscode/embedded/include LC_ALL=C LDFLAGS=-Wl,-rpath,/opt/opscode/embedded/lib -L/opt/opscode/embedded/lib LD_RUN_PATH=/opt/opscode/embedded/lib MAKE=gmake PATH=/opt/opscode/bin:/opt/opscode/embedded/bin:/home/vagrant/.gem/ruby/2.1.5/bin:/opt/rubies/ruby-2.1.5/lib/ruby/gems/2.1.0/bin:/opt/rubies/ruby-2.1.5/bin:/usr/local/bin:/home/vagrant/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/games:/usr/lib/mit/bin:/usr/lib/mit/sbin PKG_CONFIG_PATH=/opt/opscode/embedded/lib/pkgconfig gmake rel
Output:
rm -rf _rel
==> goldrush (compile)
==> lager (compile)
[Builder: chef] I | $ /opt/angrychef/embedded/bin/bundle install --without server docgen
D | Fetching gem metadata from https://rubygems.org/........
D | Fetching version metadata from https://rubygems.org/...
D | Fetching dependency metadata from https://rubygems.org/..
D | Resolving dependencies...........................................
D | Using rake 10.4.2
D | Using i18n 0.7.0
D | Using multi_json 1.11.2
D | Using activesupport 3.2.22
D | Using addressable 2.3.8
* ips_package[autoconf] action install[2016-07-26T13:21:12-07:00] INFO: Processing ips_package[autoconf] action install (/tmp/kitchen/cache/cookbooks/build-essential/resources/build_essential.rb line 60)
[2016-07-26T13:21:12-07:00] DEBUG: Providers for generic ips_package resource enabled on node include: [Chef::Provider::Package::Ips]
[2016-07-26T13:21:12-07:00] DEBUG: Provider for action install on resource ips_package[autoconf] is Chef::Provider::Package::Ips
[2016-07-26T13:21:12-07:00] DEBUG: Checking package status for autoconf
pkg: info: no packages matching the following patterns you specified are
installed on the system. Try specifying -r to query remotely:
autoconf
Name: developer/build/autoconf
Summary: GNU autoconf utility
HTTP GET https://index.rubygems.org/versions
HTTP 206 Partial Content
Fetching gem metadata from https://rubygems.org/
Looking up gems ["awesome_print", "jmespath", "aws-sdk-core", "aws-sdk-resources", "aws-sdk", "fuzzyurl", "mixlib-config", "mixlib-shellout", "chef-config", "chef-sugar", "cleanroom", "ffi", "libyajl2", "ffi-yajl", "iostruct", "ipaddress", "mixlib-cli", "mixlib-log", "mixlib-versioning", "multipart-post", "plist", "systemu", "wmi-lite", "ohai", "ruby-progressbar", "thor", "omnibus", "omnibus-software", "progressbar", "zhexdump", "pedump"]
HTTP GET https://index.rubygems.org/info/ohai
HTTP GET https://index.rubygems.org/info/omnibus
HTTP GET https://index.rubygems.org/info/chef-config
HTTP GET https://index.rubygems.org/info/ffi-yajl
HTTP 304 Not Modified
HTTP 304 Not Modified
chef_ingredient 'chefdk' do
version '0.19.6'
platform_version_compatibility_mode true
action :upgrade
end
[shain@seahain01:~/dev/ciupgra (master *)]$ kitchen converge default-centos-68
-----> Starting Kitchen (v1.13.2)
-----> Converging <default-centos-68>...
Preparing files for transfer