echo postgres://opscode_chef@localhost/opscode_chef > /etc/opscode/DATABASE_URI
cd /opt/opscode/embedded/service/opscode-account
bundle exec ./bin/createobjecttool --object-type user -a http://127.0.0.1:9465 --user-password chris4321 --object-name chris4321 --displayname chris4321 --email chris@hippiehacker4321.org --firstname Chris --middlename M --lastname McClimans --key-path /tmp/chris4321-key.pem --opscode-private-key /etc/opscode/pivotal.pem --opscode-username pivotal
bundle exec ./bin/createorgtool -t Business -a http://127.0.0.1:9465 --org-name chris4321 --customer-org-fullname chris4321-fullname --client-key-path /tmp/chris4321-validator.pem --username chris4321 --opscode-username pivotal --opscode-private-key /etc/opscode/pivotal.pem
This file contains 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
require 'rugged' | |
require 'digest' | |
class GitUtils | |
def initialize(opts={}) | |
path = opts[:path] || Dir.pwd | |
email = opts[:author_email] || "gerrit@hippiehacker.org" | |
aname = opts[:author_name] || "Gerrit HH" | |
@default_repo_name = opts[:repo_name] || "gerrit" |
This file contains 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
[30] pry(main)> conn.get_org_vdc_gateways(conn.organizations.first.id) | |
excon.request | |
:body => nil | |
:chunk_size => 1048576 | |
:ciphers => "HIGH:!SSLv2:!aNULL:!eNULL:!3DES" | |
:connect_timeout => 60 | |
:debug_request => true | |
:debug_response => true | |
:expects => 200 | |
:headers => { |
This file contains 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
$ time bundle exec knife vchs server create --winrm-password 'Miocmup4uVszX4y@' --image W2K12-STD-R2-64BIT --bootstrap-protocol winrm --customization-script ./install-winrm-2k12.bat | |
... | |
... | |
... | |
[1] pry(#<Fog::Compute::VcloudDirector::Real>)> continue | |
excon.request | |
:body => "<?xml version=\"1.0\"?>\n<GuestCustomizationSection xmlns=\"http://www.vmware.com/vcloud/v1.5\" xmlns:ovf | |
=\"http://schemas.dmtf.org/ovf/envelope/1\">\n <ovf:Info>Specifies Guest OS Customization Settings</ovf:Info>\n <Enabled>true</E | |
nabled>\n <ChangeSid>true</ChangeSid>\n <JoinDomainEnabled>false</JoinDomainEnabled>\n <UseOrgSettings>false</UseOrgSettings>\n | |
<AdminPasswordEnabled>true</AdminPasswordEnabled>\n <AdminPasswordAuto>false</AdminPasswordAuto>\n <AdminPassword>Miocmup4uVsz |
This file contains 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
@echo off | |
if “%1%” == “precustomization” ( | |
@rem First Boot | |
echo Setup WinRM for use over HTTP | |
cmd.exe /c winrm quickconfig -q | |
cmd.exe /c winrm quickconfig -transport:http | |
cmd.exe /c winrm set winrm/config @{MaxTimeoutms="1800000"} | |
cmd.exe /c winrm set winrm/config/winrs @{MaxMemoryPerShellMB="300"} | |
cmd.exe /c winrm set winrm/config/service @{AllowUnencrypted="true"} |
This file contains 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
# put this in /etc/udev/rules.d | |
# It's important that it starts with 99 or something high | |
# If this file is 10-local.rules it will fail to run the scripts | |
ACTION=="change", SUBSYSTEM=="drm", RUN+="/etc/udev/monitor.change.sh" |
This file contains 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
# On Arch Drop this file into /etc/sysctl.d/ | |
# and run sysctl --system | |
# on other systems put in /etc/sysctl.conf | |
# http://discussions.citrix.com/topic/277290-kswapd0-process-consumes-a-guest-vm/#entry1511105 | |
vm.dirty_background_ratio = 3 | |
# (default was 10, had tried 5)) | |
vm.dirty_expire_centisecs = 500 |
This file contains 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
# From https://github.com/fotinakis/bashrc/blob/master/init.sh#L35 | |
export HISTFILESIZE= | |
export HISTSIZE= | |
export HISTIMEFORMAT="[%F %T] " | |
export HISFILE=~/.bash_eternal_history | |
PROMPT_COMMAND="history -a; $PROMPT_COMMAND" | |
# https://github.com/joshuacronemeyer/shellsink | |
# is a centralized web based version for all your shells, I didn't look at it | |
# but it's an interesting concept |
This file contains 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
bundle exec chef-client -z ./examples/simple.rb | |
DL is deprecated, please use Fiddle | |
Starting Chef Client, version 11.16.0 | |
resolving cookbooks for run list: [] | |
Synchronizing Cookbooks: | |
Compiling Cookbooks... | |
[2014-09-09T14:13:52-05:00] WARN: Node mba.grandenetworks.net has an empty run list. | |
Converging 1 resources | |
Recipe: @recipe_files::/home/hh/discovery/preview/examples/simple.rb | |
* machine[mario] action converge |
This file contains 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
[hh@mba test]$ knife data bag show secrets github -s .chef/encrypted_data_bag_secret -k .chef/invalidation.pem -u foo --server-url http://localhost:8889 | |
api_key: aoeuaoeu | |
api_secret: aoeu | |
id: github | |
[hh@mba test]$ ssh -i /home/hh/.chef/keys/metal_default root@192.241.229.152 -R 8889:localhost:8889 knife data bag show secrets github -s /etc/chef/encrypted_data_bag_secret -c /etc/chef/client.rb | |
ERROR: Chef::EncryptedDataBagItem::DecryptionFailure: Error decrypting data bag value: 'bad decrypt'. Most likely the provided key is incorrect | |
[hh@mba test]$ cat .chef/encrypted_data_bag_secret | |
MIIBOgIBAAJBALiIoYZz3vG9NdL1ETExJF884dMTlBN2ikpFNdEu5+M0G0RlK5cS | |
kEJC93nkWvN0cifjDdxedNsjqe5LtPuosBUCAwEAAQJAQaYB6MZCEzgf9NvQcPKt | |
oOAU6rW1YTMzwXZbzf5k6pPdK1m9BS5Tsm5r0HLeig4v5A9XqHi7mojIaQDqrTq7 |
OlderNewer