Skip to content
This repository has been archived by the owner on Mar 5, 2018. It is now read-only.

rosenhouse/tubes

Repository files navigation

tubes

Build Status

work in progress + side project == be careful

Huh?

A CLI tool that automates the creation of a BOSH on AWS

You probably want to look at the BOSH Bootloader instead.

Goals

  • Automate as much as possible
  • Minimize required human configuration
  • Ease common existing workflows, don't try to replace them
  • Encourage disposability of environments

Contributing

Pull requests are welcome. Here's how to get started:

  1. Get the source and dependencies
[ -d $GOPATH ] && cd $GOPATH
mkdir -p src/github.com/rosenhouse && cd src/github.com/rosenhouse
git clone git://github.com/rosenhouse/tubes
cd tubes
git submodule update --init --recursive
  1. Run the offline test suite
./scripts/test-offline
  1. Run the online test suite (optional)

Requires AWS account region & credentials in your environment. Takes a while, as it creates real resources on AWS.

./scripts/test-full  # WARNING: this uses a REAL AWS account and will cost you real money.

What it does today

Here's a brief walkthrough. Run with -h flag to see all options. There are still several manual steps. Automating those is a high priority.

  1. Install for easy access
go install github.com/rosenhouse/tubes/cmd/tubes
  1. Set your AWS environment variables
AWS_DEFAULT_REGION=us-west-2
AWS_ACCESS_KEY_ID=some-key
AWS_SECRET_ACCESS_KEY=some-secret
  1. Boot a new environment named my-environment
tubes -n my-environment up

This boots 2 CloudFormation stacks, a "base" stack to support a BOSH director, and a "Concourse" stack with dedicated subnet and Elastic LoadBalancer. It generates deployment manifests in $PWD/environments/my-environment

Things you can do manually

things to automate eventually ...

  1. Manually bosh-init the director
cd environments/my-environment
source bosh-environment
scp -i ssh-key ./* ec2-user@$NAT_IP:~/
ssh -i ssh-key ec2-user@$NAT_IP "bosh-init deploy director.yml"
scp -i ssh-key ec2-user@$NAT_IP:~/director-state.json ./

or to run the deploy in a detached screen that survives hangups, try

ssh -i ssh-key ec2-user@$NAT_IP "screen -S setup -d -m bosh-init deploy director.yml"

instead. In that case you'll need to wait for it to finish before copying the director-state.json file back down to your local box.

  1. Target the new bosh director
bosh -t $BOSH_TARGET status --uuid

About

for booting things

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published