I hereby claim:
- I am joshkraemer on github.
- I am joshkraemer (https://keybase.io/joshkraemer) on keybase.
- I have a public key ASCllDHLpiNl7sf_chuJShruHKSGXrghWfMQPMfTHuWfiQo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
echo "deb http://apt.postgresql.org/pub/repos/apt/ trusty-pgdg main" | sudo tee /etc/apt/sources.list.d/pgdg.list | |
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add - | |
sudo apt-get update | |
sudo apt-get install postgresql-9.3 postgresql-server-dev-9.3 postgresql-contrib-9.3 -y | |
sudo su - postgres -c "psql template1 -p 5433 -c 'CREATE EXTENSION IF NOT EXISTS hstore;'" | |
sudo su - postgres -c "psql template1 -p 5433 -c 'CREATE EXTENSION IF NOT EXISTS \"uuid-ossp\";'" | |
sudo su - postgres -c "service postgresql stop" | |
sudo su - postgres -c '/usr/lib/postgresql/9.3/bin/pg_upgrade -b /usr/lib/postgresql/9.1/bin -B /usr/lib/postgresql/9.3/bin -d /var/lib/postgresql/9.1/main/ -D /var/lib/postgresql/9.3/main/ -O "-c config_file=/etc/postgresql/9.3/main/postgresql.conf" -o "-c config_file=/etc/postgresql/9.1/main/postgresql.conf"' | |
Here are the steps on how to get MySQL working with MAMP and Rails Projects: | |
Note: If you already have MAMP installed and you update the mysql2 gem, you'll need to run steps 4-6 to change the gem version that is linked to MAMP. | |
1.) Download and install MAMP (if it's not already installed) - http://www.mamp.info/downloads/releases/MAMP_PRO.zip | |
2.) Add these lines to your .bash_profile file. Be sure to remove any existing lines that reference MAMP. | |
export DYLD_LIBRARY_PATH=/usr/local/mysql/lib:$DYLD_LIBRARY_PATH | |
export PATH="/Applications/MAMP/Library/bin:$PATH" |
# Load Amazon EC2 API tools | |
source ~/.ec2/setup_env.sh |
# Recursively find all files named config and replace a string using sed. The -i flag requires a blank suffix '' to work on Mac. | |
find . -name config -type f -print | xargs sed -i '' 's/[email protected]:CollegePlus/[email protected]:collegeplus/g' | |
# Recursively find all files with a certain file extension and replace a string using perl. | |
find . -name "*.fileext" -print | xargs perl -i -p -e 's/STRINGTOFIND/STRINGTOREPLACE/g' | |
# Display filesystem of mounted volumes | |
df -T | awk '{print $1,$2,$NF}' | grep "^/dev" | |
# Recursively force files lowercase with rename |
#!/bin/sh | |
### BEGIN INIT INFO | |
# Provides: unicorn | |
# Required-Start: $local_fs $remote_fs | |
# Required-Stop: $local_fs $remote_fs | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: S 0 1 6 | |
# Short-Description: unicorn initscript | |
# Description: unicorn | |
### END INIT INFO |
# /etc/nginx/mime.types | |
# Global Nginx mime.types file | |
types { | |
text/html html htm shtml; | |
text/css css; | |
text/xml xml rss; | |
image/gif gif; | |
image/jpeg jpeg jpg; | |
application/javascript js; |