Skip to content

ganguera/docker

Repository files navigation

Proof of concept to integrate Docker, Consul and progrium/registrator

Run a three nodes Consul cluster, a couple of frontend nodes and one backend node.

Services provided:

  • Consul Service Discovery
  • cAdvisor
  • nginx (as a reverse proxy)
  • Custom app
    • Bottle app
    • Redis
  • Wordpress
    • PHP Built-in web server
    • MySQL

Requirements

Optional but recommended

Usage

  1. Clone this repository
  2. Execute vagrant up to start the six nodes
  3. SSH in every node vagrant ssh ${HOSTNAME}
  4. From "/home/vagrant/${HOSTNAME}" execute sudo fig up to start every container
  5. Modify your local "/etc/hosts" sudo -- sh -c "echo 172.16.10.14 app.example.com wordpress.example.com >> /etc/hosts"

You'll find the following things at:

Warning:

The nginx container in frontend-01 will fail if it starts before both the "web" and "wordpress" services (containers) are registered in Consul. If this happens, please check both containers are running and rerun again the nginx container from "frontend-01:/home/vagrant/frontend-01": sudo fig up nginx

About

Development environment with VirtualBox / Vagrant, Docker, Consul

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published