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
| # slides | |
| Available at: | |
| https://dl.dropboxusercontent.com/u/48553683/quick-devops-hacks-devopsmtl-2014.pdf | |
| # show the exit status in your $PS1 | |
| Article and code at: | |
| https://ttboj.wordpress.com/2014/01/29/show-the-exit-status-in-your-ps1/ | |
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
| #!/bin/bash | |
| if [ "$1" = '' ]; then | |
| echo "Usage: ./`basename "$0"` <hostname>" | |
| exit 1 | |
| fi | |
| # NOTE: lets say you try to provision a previously provisioned host... | |
| # $ vp foo | |
| # [foo] Configuring cache buckets... |
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
| # run nethogs on the interface that is being used for the default route | |
| function nethogs { | |
| dev=`ip r | grep '^default' | awk '{print $5}'` | |
| #echo $dev | |
| if [ `id -u` -eq 0 ]; then | |
| nethogs $@ $dev | |
| else | |
| sudo nethogs $@ $dev | |
| fi |
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
| # vagrant vsftp and other tricks | |
| # from: https://ttboj.wordpress.com/2013/12/21/vagrant-vsftp-and-other-tricks/ | |
| # and | |
| # Vagrant clustered SSH and 'screen' | |
| # from: https://ttboj.wordpress.com/2014/01/02/vagrant-clustered-ssh-and-screen/ | |
| # for use inside a ~/.bashrc or similar | |
| # copyright James Shubin, 2013, agplv.3+ | |
| ### VAGRANT ################################################################### | |
| # avoid needing to always add --provider=kvm |
NewerOlder