Skip to content

Instantly share code, notes, and snippets.

View shortdudey123's full-sized avatar

Grant Ridder shortdudey123

View GitHub Profile
@shortdudey123
shortdudey123 / output_alpine.txt
Created November 3, 2016 00:59
Ruby Socket.gethostbyname random failures
ruby:2.3.1-alpine
/ # ruby test.rb
Failed after 10729 successes
SocketError
getaddrinfo: Try again
test.rb:8:in `gethostbyname'
test.rb:8:in `<main>'
/ #
/ # ruby --version

Keybase proof

I hereby claim:

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

To claim this, I am signing this object:

@shortdudey123
shortdudey123 / setup_vnc.sh
Created May 12, 2015 22:15
Add desktop and VNC to Ubuntu on AWS
#!/bin/sh
# Created by: Grant Ridder <shortdudey123@gmail.com>
# Instructions taken from the below link unless noted
# http://stackoverflow.com/questions/25657596/how-to-set-up-gui-on-amazon-ec2-ubuntu-server
# SET THESE VARIABLES TO YOUR OWN!!!
# begin
VNC_PASSWORD="<password up to 8 char long>"
SSH_KEY="</path/to/your/ec2/ssh/key.pem>"
# end
@shortdudey123
shortdudey123 / change.sh
Created July 28, 2014 07:53
Change filename and update words in file
#!/bin/bash
echo "What directory would you like to execute this script on?"
echo "NOTE: do not execute this on the same directory that contains this script"
read FILEPATH
for file in $(echo $FILEPATH*); do
filenew=`echo $file | sed 's/foo/bar/g'`
if [ "$filenew" != "$file" ]