No description, website, or topics provided.
Switch branches/tags
Nothing to show
Clone or download
Pull request Compare This branch is 3 commits ahead, 4 commits behind bellycard:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.envrc
Dockerfile
README.md
app.conf
consul-template.service
fig.yml
nginx.conf
nginx.service

README.md

Installing Prerequisites

brew update
brew install caskroom/cask/brew-cask
brew cask install boot2docker
brew install fig

Optionally, you can use direnv to automatically set some environment variables, sourced from .envrc:

brew install direnv
direnv allow .

Readying Docker

boot2docker init
boot2docker upgrade
boot2docker up
docker version
docker ps

Boot The App

From the root of the repository:

fig pull && fig build
fig up -d

Inspection

Consul Registered Services

curl http://`boot2docker ip 2>/dev/null`:8500/v1/catalog/services

Visit LB In Default Browser

open "http://`boot2docker ip 2>/dev/null`/"

Adding/Removing Backend Containers

fig scale app=4
fig scale app=1

Gotchas

  • The auto-detected advertise IP for Consul-in-Docker on Boot2docker does not appear to be routable from the Nginx container. Use the following to look up the IP to set for -advertise:
boot2docker ssh ifconfig eth0 | grep 'inet addr'