Example of using Vendor MIME Types to determine how to route a request coming into a Rails application.
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
yum -y install rpm-build | |
wget http://monkey.org/~provos/libevent-1.3e.tar.gz | |
tar zxpfv libevent* | |
cd libevent* ; ./configure; make ; make install DESTDIR=/tmp/intu-rhel5-libevent-1.3e | |
fpm --prefix=/ -s dir -t rpm -n intu-libevent -v 1.3e -C /tmp/intu-rhel5-libevent-1.3e -p /tmp/intu-rhel5-libevent-1.3e.rpm |
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 | |
# Create an open ssl cert and key to upload to IAM account | |
NAME=$1 | |
if [ -z $1 ]; then | |
echo 'Plese provide a cert name.' | |
exit 1 | |
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
#!/bin/bash | |
# For latest cloud init source see | |
# http://aws.amazon.com/developertools/4026240853893296 | |
# Download archive | |
wget https://s3.amazonaws.com/cloudformation-examples/aws-cfn-bootstrap-1.0-6.zip | |
# Unzip archive | |
unzip aws-cfn-*.zip |
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 | |
ssh -i<%= @node[:deploy][:key_path] %>/<%= @appname %>_deploy_key -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no $1 $2 |
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 [ `whoami` != root ]; then | |
echo "---- Please run this as the 'root' user"; | |
exit 1 | |
fi | |
# Static settings | |
dir=/etc/chef/lwe-repo | |
md_file=/etc/chef/metadata.json |
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 | |
#--------------------------------------------------------------- | |
# | |
# rc.local | |
# | |
# This script is executed at the end of each multiuser runlevel. | |
# Make sure that the script will "exit 0" on success or any other | |
# value on error. | |
# |
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
cd chef-repo | |
git submodule init ; git submodule update | |
cd cookbooks | |
git checkout master | |
git pull |
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
cd /tmp | |
umask 022 | |
wget http://s3.amazonaws.com/ec2-downloads/ec2-api-tools.zip | |
unzip ec2-api-tools.zip | |
fpm -s dir -t rpm -n intu-amzn-ec2-tools -v 1.5.5.0 -p /tmp/intu-amzn-ec2-tools-1.5.5.0.rpm --prefix=/usr -C /tmp/ec2-api-tools-1.5.5.0 lib bin |
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
# Generate the csr / key | |
openssl genrsa -des3 -out server.key 1024 | |
# Generate the CSR | |
openssl req -new -key server.key -out server.csr | |
# Remove the password from the key | |
cp server.key server.key.org | |
openssl rsa -in server.key.org -out server.key |