bosh-install

Tutorial for installing bosh with terraform

View project on GitHub

Manual Installation of Bosh

This document outlines manual scripts that ar automated in the actual tutorial.

Install inception VM

  1. Configure your AWS (for details see bosh.io; NOTE: Do not perform the bosh-init steps, this will be done in the remainder; only prepare your AWS)
    1. Create a Virtual Private Cloud (VPC) with a Single Public Subnet
    2. Create an Elastic IP
    3. Create a Key Pair - Output: bosh.pem
    4. Create a second pair of keys - Output deployer.pem
    5. Create and Configure Security Group
  2. Setup a jumpbox instance on AWS. From this machine you will perform the bosh setup.
    1. Manually start an Ubuntu machine in the ec2 management console.
    2. Make sure that the instance is running in the bosh network (see step 1).
  3. SSH to the jumpbox instance.
     ssh -i "deployer.pem" ubuntu@< see console for id >
    
  4. Install gcc, ruby, and other prerequisites on the jumpbox instance.
     sudo apt -y install git gcc make ruby zlibc zlib1g-dev ruby-bundler ruby-dev build-essential patch libssl-dev bison openssl libreadline6 libreadline6-dev curl git-core libssl-dev libyaml-dev libxml2-dev autoconf libc6-dev ncurses-dev automake libtool
    

Install bosh via bosh-cli v2

  1. SCP prepared key (bosh.pem, see step 1 of aws installation) to the jumpbox instance.
  2. Clone bosh deployment repository
    git clone https://github.com/cloudfoundry/bosh-deployment.git
    
  3. Install the bosh-cli.
     wget https://s3.amazonaws.com/bosh-cli-artifacts/bosh-cli-2.0.1-linux-amd64
     mv bosh-cli-2.0.1-linux-amd64 bosh
     chmod +x bosh
     sudo mv bosh /usr/local/bin
    
  4. Follow bosh-deployment instructions to deploy bosh.
    1. For details see https://github.com/cloudfoundry/bosh-deployment
    2. Make sure your AWS bosh-director has a public ip.
    3. Install stemcell:
       bosh -e bosh-1 upload-stemcell https://bosh.io/d/stemcells/bosh-aws-xen-hvm-ubuntu-trusty-go_agent
      

Configure UAA

  1. On the jumpbox install the uaac gem
     gem install cf-uaac
    
  2. Extract root ca to a file uaa.pem from the credentials file creds.yml
  3. Login to uaa via credentials from creds.yml
     uaac target https://10.0.0.6:8443 --ca-cert uaa.pem
     uaac token client get admin