Skip to content

Instantly share code, notes, and snippets.

View fifteen3's full-sized avatar

Carlo Costantini fifteen3

View GitHub Profile
@fifteen3
fifteen3 / keybase.md
Last active February 27, 2017 04:51
keybase.md

Keybase proof

I hereby claim:

  • I am fifteen3 on github.
  • I am fifteen3 (https://keybase.io/fifteen3) on keybase.
  • I have a public key ASBwrrMpc9W1A7GzhdRIOizM3ce14_UKZPmDpnnMinZw8Ao

To claim this, I am signing this object:

@fifteen3
fifteen3 / gist:7531194
Created November 18, 2013 16:52
Vagrant Shell provisioner for returning the ip address of your vm.
#typically you need this for a dhcp public network setup
#with private networks you set the ip address but it is still useful
#to have this provisioner if you reload the vagrant file as it will remind
#you what the ip address is, so you can set it in your host file.
#use eth0 if the network is public, eth1 if the network is private
$network_interface = "eth0"
$display_ip_address = <<IP_ADDRESS
ipaddress=`/sbin/ifconfig #{$network_interface} | grep 'inet addr' | awk -F' ' '{print $2}' | awk -F':' '{print $2}'`
echo "ip address: $ipaddress"