# This script performs a complete installation of Gitlab (master branch).
# Is can be run with one command without needing _any_ user input after that.
# This script only works on Amazon Web Services (AWS).
# The operating system used is Ubuntu 12.04 64bit.
# TODO
# @dosire will send a pull request after this is merged in to change dosire/gitlabhq/non-interactive-aws-install links to gitlabhq/gitlabhq/master and reference this script from installation.md
# HOWTO
# Signup for AWS, free tier are available at http://aws.amazon.com/free/
# Go to EC2 tab in the AWS console EC2 https://console.aws.amazon.com/ec2/home
# Click the 'Launch Instance' button
# Select: 'Quick launch wizard' and continue
# Choose a key pair => Create New => Name it => Download it
sudo sed-i's/YOUR_SERVER_IP/'`wget -qO- http://instance-data/latest/meta-data/local-ipv4`'/' /etc/nginx/sites-available/gitlab # Set private ip address (public won't work).
sudo sed-i's/YOUR_SERVER_FQDN/'`wget -qO- http://instance-data/latest/meta-data/public-hostname`'/' /etc/nginx/sites-available/gitlab # Set public dns domain name.