Skip to content

Instantly share code, notes, and snippets.

View slyness's full-sized avatar
🏠
Working from home

Aaron Baer slyness

🏠
Working from home
View GitHub Profile
@slyness
slyness / gist:5807528
Created June 18, 2013 17:33
vagabond init error
Aarons-MacBook-Air :: hw/private-docs/ninefold ‹master› » cat jira.md * https://jira.ninefold.com* user: chris@hw-ops.com* https://jira.ninefold.com* user: chris@hw-ops.com
17: Array(val[:routes]).map do |route|
18: if(route[:family] == 'inet' && route[:destination].start_with?('10.0'))
19: route[:destination].split('/').first.split('.')[3].to_i
20: end
21: end
22: end.compact.max
23:
24>> node.default[:vagabond][:lxc_network][:oct] = max ? max + 1 : 0
@slyness
slyness / gist:5807788
Created June 18, 2013 18:04
do something sweetspot
bundle exec scripts/aws_environment.sh
says what you need to do to create
Use to create the .ec2 directory
scripts/vpn_authtool dev gencert aaronb
scripts/vpn_authtool dev sign aaronb.csr aaronb
that should dump out a dev.tblk folder which you can put your key into, and 'sudo openvpn dev.ovpn'
'aws_environment dev' will set up your shell, knife etc for talking to our hw dev org
@slyness
slyness / gist:5816223
Created June 19, 2013 17:37
vagabond init Failed
GreenLantern :: Planet/ninefold/ninefold-vagabond » vagabond init 1 ↵
Ensuring expected system state (creating required base containers)
- This can take a while on first run or new templates...
Expected process to exit with [0], but received '1'
---- Begin output of sudo chef-solo -j /tmp/vagabond/solos/home/aaronb/Planet/ninefold/ninefold/vagabond/.vagabond/dna.json -c /tmp/vagabond/solos/home/aaronb/Planet/ninefold/ninefold/vagabond/.vagabond/solo.rb ----
STDOUT: [2013-06-19T10:34:52-07:00] INFO: *** Chef 11.4.4 ***
[2013-06-19T10:34:52-07:00] INFO: Setting the run_list to ["recipe[vagabond]"] from JSON
[2013-06-19T10:34:52-07:00] INFO: Run List is [recipe[vagabond]]
[2013-06-19T10:34:52-07:00] INFO: Run List expands to [vagabond]
[2013-06-19T10:34:52-07:00] INFO: Starting Chef Run for GreenLantern
@slyness
slyness / gist:6058600
Created July 22, 2013 23:27
restore script issue
root@ubuntu:~# /usr/local/bin/restore_db -p ninefold -c "token=THEAWESOMETOKENUSEDHERE,user=nftwodbstorage" -r backups/postgresql/pg/2013.07.22.23.05.33/pg.tar -d kandan
/opt/chef/embedded/lib/ruby/gems/1.9.1/gems/fog-1.10.1/lib/fog/core/service.rb:208:in `validate_option
s': Missing required arguments: ninefold_storage_token, ninefold_storage_secret (ArgumentError)
from /opt/chef/embedded/lib/ruby/gems/1.9.1/gems/fog-1.10.1/lib/fog/core/service.rb:58:in `new
@slyness
slyness / gist:6226095
Created August 13, 2013 21:53
Berksfile.full
site :opscode
cookbook 'ninefold_app', path: '/home/aaronb/Planet/ninefold/chef-ninefold-app', branch: 'develop'
cookbook 'ninefold_ohai', path: '/home/aaronb/Planet/ninefold/chef-ninefold-ohai', branch: 'develop'
cookbook 'ninefold_repo_builder', git: 'git@github.com:ninefold/chef-ninefold-repo-builder.git', branch: 'develop'
cookbook 'ninefold_logger', path: '/home/aaronb/Planet/ninefold/chef-ninefold-logger', branch: 'develop'
cookbook 'backup', path: '/home/aaronb/Planet/ninefold/backup/', branch: 'feature/many_databases'
cookbook 'minitest-handler'
@slyness
slyness / gist:6441895
Created September 4, 2013 19:45
postgres ssl for NF
bev ssh to_host;
cut and paste as root.
cd /var/lib/postgresql/9.1/main/;
cp /etc/ssl/certs/ssl-cert-snakeoil.pem server.crt;
cp /etc/ssl/private/ssl-cert-snakeoil.key server.key;
chown postgres:postgres server*;
service postgresql start;
on 12.04
root@ubuntu_1204-Mp5FUZ2yj7JV:/opt/chef/embedded/bin# dpkg -l | grep whiptail
ii whiptail 0.52.11-2ubuntu10 Displays user-friendly dialog boxes from shell scripts
turns into:
"binary-Displays": {
"whiptail": [
"0.52.11-2ubuntu10"
@slyness
slyness / gist:8063720
Created December 21, 2013 00:25
apt smash!
root@ubuntu_1204-orfqR8eue34M:/etc/apt/preferences.d# apt-cache policy wget
wget:
Installed: (none)
Candidate: 1.13.4-2ubuntu1
Version table:
1.13.4-2ubuntu1 0
999 http://apt.ninefold.slyness.org/ precise/ninefold amd64 Packages
500 http://archive.ubuntu.com/ubuntu/ precise/main amd64 Packages
vagrant 1.4.2
vagabond 0.2.10
.vagabond/Cheffile
site 'http://community.opscode.com/api/v1'
cookbook 'vagabond', '1.0.4'
cookbook 'lxc', '1.1.4'
cookbook 'chef-server-populator', '0.3.0'
@slyness
slyness / gist:8292532
Created January 7, 2014 00:20
some more issue
elecksee status:
greenlantern :: Planet/ninefold/ninefold-test ‹master*› » gem query --local | grep elecksee
elecksee (1.0.18, 1.0.16, 1.0.10, 1.0.6, 1.0.4)
greenlantern :: Planet/ninefold/ninefold-test ‹master*› » bundle exec gem query --local | grep elecksee
elecksee (1.0.18)
greenlantern :: Planet/ninefold/ninefold-test ‹master*› » /opt/chef/embedded/bin/gem query --local | grep elecksee
elecksee (1.0.18, 1.0.16, 1.0.10, 1.0.6, 1.0.4)
New Error: