Skip to content

Instantly share code, notes, and snippets.

13:47:36 [ dev.bravo.cloudcruiser.com ] [ cc-dev ] [ ~/vagrant_images ]
$ cd ubuntu-1510-64/
13:47:41 [ dev.bravo.cloudcruiser.com ] [ cc-dev ] [ ~/vagrant_images/ubuntu-1510-64 ]
$ vagrant init ubuntu/wily64; vagrant up --provider virtualbox
A `Vagrantfile` has been placed in this directory. You are now
ready to `vagrant up` your first virtual environment! Please read
the comments in the Vagrantfile as well as documentation on
`vagrantup.com` for more information on using Vagrant.
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Box 'ubuntu/wily64' could not be found. Attempting to find and install...
@majormoses
majormoses / terraform-0.7.3-make-vet
Created September 14, 2016 15:55
Failing on make vet when building 0.7.3
08:48:27 [ /opt/gopath/src/github.com/hashicorp/terraform (git, (v0.7.3), *%) ]
$ make vet
go tool vet -all .
builtin/providers/aws/resource_aws_efs_mount_target_test.go:214: arg mount.MountTargetId for printf verb %s of wrong type: *string
Vet found suspicious constructs. Please check the reported constructs
and fix them if necessary before submitting the code for review.
Makefile:69: recipe for target 'vet' failed
make: *** [vet] Error 1
@majormoses
majormoses / gist:ea92b8a209cde662238b0d655fc29c95
Created November 18, 2016 19:06
Sensu client fails to restart because of gemspec permissions (umask)
2016-11-18_18:52:14.96829 ================================================================================ESC[0m
2016-11-18_18:52:14.96833 ESC[31mError executing action `restart` on resource 'service[sensu-client]'ESC[0m
2016-11-18_18:52:14.96836 ================================================================================ESC[0m
2016-11-18_18:52:14.96840
2016-11-18_18:52:14.96841 ESC[0mMixlib::ShellOut::ShellCommandFailedESC[0m
2016-11-18_18:52:14.96848 ------------------------------------ESC[0m
2016-11-18_18:52:14.96852 Expected process to exit with [0], but received '1'
2016-11-18_18:52:14.96853 ESC[0m---- Begin output of /etc/init.d/sensu-client restart ----
2016-11-18_18:52:14.96854 ESC[0mSTDOUT:
2016-11-18_18:52:14.96856 ESC[0mSTDERR: /opt/sensu/embedded/lib/ruby/site_ruby/2.3.0/rubygems/stub_specification.rb:111:in `initialize': Permission denied @ rb_sysopen - /opt/sensu/embedded/lib/ruby/gems/2.3.0/specifications/sensu-plugins-nginx-2.0.0.gemspec (Errno::EACCES)
@majormoses
majormoses / make-tf-0.8.1
Created December 15, 2016 23:28
Issues compiling v0.8.1
$ git checkout v0.8.1
Note: checking out 'v0.8.1'.
You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.
If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:
@majormoses
majormoses / error-in-jenkins-with-jsonlint
Last active February 13, 2017 22:28
Make from Jenkins with jsonlint and oj
```
ruby --version
ruby 2.2.5p319 (2016-04-26 revision 54774) [x86_64-linux]
bundle --version
Bundler version 1.14.3
bundle install --path vendor/bundle
Using rake 11.3.0
Using addressable 2.4.0
Using artifactory 2.3.3
Using ast 2.3.0
@majormoses
majormoses / babrams.json
Created February 7, 2017 13:36
Users dbag
{
"id": "babrams",
"ssh_keys": [
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDMCKMvMJ2yb13pHLsIPqi2xHOBKFZKa8+FM1FUqNbIxKeq3LLw+4WiXLK60DxxS6hmOnXD+FcWNaykkGLyGQeYHxsHynsXo9BPaG/ewaAp5SDU/zAIAaex15s/zvo5l+5Pq9OwXYtFRmfezk3ImCx7SZ8sMmHiFHYD8d38XBlGX53kLSFm5HLEopEvSCRTUyTj+tPIspgYR6IvCTdXnamO9FT8Rkeqw+mqjX9sVTaLuuqwQZlRFRMslrrJbSfv+7XvyKsjOsmAlkEYRlpHbUCxUh2Hc5q2Wfm+acOHPkkUPX8kLeT2vW+Bd/9LlPi9BN0dbmazGPbf5kv02MRNQNeUrdRfdzRIOG4tUEv154msF7QdEuy9W4pv9p0z2rNOqOQEw9HPhMiAkftIVGnvvGRj9+jIARIVzV5gAfVm2DQbPJClr0tGNCfzHmndt6FddawubXFPvFNrKgdC38Ts0Jzl1F3aWGHT8UyURDbezrTGpxg+Cqq4YUXIZfrrqB8nzF8qK3eMW2Tcxdy2m+fFBzQeHlozBSP55dcdjekdQrcVcwkYux4jecJ9BU++DjWtMtY93LgVL5BnHixS4ybo7loCndYkpsI6ZZm9oLVxHsjeoaM9D9iYoN28LIlALBm/dnfCh92G/H40v/X25DMIvRqcfnE31gsOCJ85A29twSC+Cw== babrams@system76.servalws",
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQCy3cbPekJYHAIa8J1fOr2iIqpx/7pl4giJYAG7HCfsunRRUq3dY1KhVw1BlmMGIDzNwcuNVIfBS5HS/wREqbHMXxbwAjWrMwUofWd09CTuKJZiyTLUC5pSQWKDXZrefH/Fwd7s+YKk1s78b49zkyDcHSnKxjN+5veinzeU+vaUF9duFAJ9OsL7kTDE
---
driver:
name: dokken
chef_version: 12.9.41
privileged: true
transport:
name: dokken
verifier:
@majormoses
majormoses / kitchen.log
Created February 13, 2017 17:19
ops_chef-cc_sensu/.kitchen/logs when trying dokken 2.x
I, [2017-02-10T16:27:05.456011 #12077] INFO -- Kitchen: -----> Starting Kitchen (v1.15.0)
I, [2017-02-10T16:27:05.725173 #12077] INFO -- Kitchen: -----> Cleaning up any prior instances of <sensu-client-ubuntu-1404>
I, [2017-02-10T16:27:05.727598 #12077] INFO -- Kitchen: -----> Destroying <sensu-client-ubuntu-1404>...
I, [2017-02-10T16:27:05.742441 #12077] INFO -- Kitchen: -----> Testing <sensu-client-ubuntu-1404>
I, [2017-02-10T16:27:05.742486 #12077] INFO -- Kitchen: -----> Creating <sensu-client-ubuntu-1404>...
I, [2017-02-10T16:27:30.644182 #12077] INFO -- Kitchen: -----> Cleaning up any prior instances of <sensu-ext-monitor-ubuntu-1404>
I, [2017-02-10T16:27:30.647393 #12077] INFO -- Kitchen: -----> Destroying <sensu-ext-monitor-ubuntu-1404>...
I, [2017-02-10T16:27:30.659418 #12077] INFO -- Kitchen: -----> Testing <sensu-ext-monitor-ubuntu-1404>
I, [2017-02-10T16:27:30.659461 #12077] INFO -- Kitchen: -----> Creating <sensu-ext-monitor-ubuntu-1404>...
I, [2017-02-10T16:28:01.693998 #12077] INFO --
# look at json file
$ cat data_bags/users/babrams.json
{
"id": "babrams",
"ssh_keys": [
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDMCKMvMJ2yb13pHLsIPqi2xHOBKFZKa8+FM1FUqNbIxKeq3LLw+4WiXLK60DxxS6hmOnXD+FcWNaykkGLyGQeYHxsHynsXo9BPaG/ewaAp5SDU/zAIAaex15s/zvo5l+5Pq9OwXYtFRmfezk3ImCx7SZ8sMmHiFHYD8d38XBlGX53kLSFm5HLEopEvSCRTUyTj+tPIspgYR6IvCTdXnamO9FT8Rkeqw+mqjX9sVTaLuuqwQZlRFRMslrrJbSfv+7XvyKsjOsmAlkEYRlpHbUCxUh2Hc5q2Wfm+acOHPkkUPX8kLeT2vW+Bd/9LlPi9BN0dbmazGPbf5kv02MRNQNeUrdRfdzRIOG4tUEv154msF7QdEuy9W4pv9p0z2rNOqOQEw9HPhMiAkftIVGnvvGRj9+jIARIVzV5gAfVm2DQbPJClr0tGNCfzHmndt6FddawubXFPvFNrKgdC38Ts0Jzl1F3aWGHT8UyURDbezrTGpxg+Cqq4YUXIZfrrqB8nzF8qK3eMW2Tcxdy2m+fFBzQeHlozBSP55dcdjekdQrcVcwkYux4jecJ9BU++DjWtMtY93LgVL5BnHixS4ybo7loCndYkpsI6ZZm9oLVxHsjeoaM9D9iYoN28LIlALBm/dnfCh92G/H40v/X25DMIvRqcfnE31gsOCJ85A29twSC+Cw== babrams@system76.servalws",
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQCy3cbPekJYHAIa8J1fOr2iIqpx/7pl4giJYAG7HCfsunRRUq3dY1KhVw1BlmMGIDzNwcuNVIfBS5HS/wREqbHMXxbwAjWrMwUofWd09CTuKJZiyTLUC5pSQWKDXZrefH/F
@majormoses
majormoses / gist:da89381260a814046e4003d677c110e1
Created April 19, 2017 18:59
Removing rmq node from cluster using reset
# validating the nodes in a cluster from a machine
babrams@ip-10-55-250-69:~$ sudo rabbitmqctl cluster_status | grep rmq | cut -d\@ -f2 | grep -Eo "ip\-[0-9]+\-[0-9]+\-[0-9]+\-[0-9]+" | sort | uniq
ip-10-55-250-69
ip-10-55-251-128
ip-10-55-252-176
# validating the same from another machine
babrams@ip-10-55-251-128:~$ sudo rabbitmqctl cluster_status | grep rmq | cut -d\@ -f2 | grep -Eo "ip\-[0-9]+\-[0-9]+\-[0-9]+\-[0-9]+" | sort | uniq
ip-10-55-250-69
ip-10-55-251-128