Public Repository

Last pushed: a year ago
Short Description
Deploy Docker to Mesosphere, Compose and many others
Full Description

Overview

Depcon makes managing clusters that run docker containers a breeze. It offers the ability to define environments such as test, pre-prod, production against Marathon (initial release), Kubernetes and Amazon ECS.

Some key features of Depcon are:

  • Variable substistution in deployment descriptors
  • Output results in Column, YAML and JSON formats for easy integration with automation
  • Accepts deployment descriptors in either JSON or YAML format
  • Full Mesos/Marathon support
    • Application, Group & Task management
    • Partial application updates: CPU, Memory & Scaling
    • Quick application rollback
    • Leader election, Server info and elapsed response
  • Docker compose support
    • Supports all major operating systems
    • Works with Docker Machine aka Boot2Docker
    • Adds param support -- ${PARAMS} can be placed in compose files
  • Future releases will offer a proposed Open Deployment Descriptor format which will allow Depcon to deploy a common descriptor against Marathon, Kubernetes, ECS and Docker Swarm.
  • Ability to wait until a new or updated container deployment is healthy

Running

Normally when depcon is being used outside of docker it requires you to build a config file (via its wizard) containing information about your deployment environments. This workflow is slightly different when running within Docker.

Currently depcon in docker only supports Marathon deployments. Running depcon for compose would require us to have docker-in-docker setup. These docs will be updated in the future with instructions on how to accomplish that.

Using Depcon in Docker with Environment Variables

Inline

docker run -e DEPCON_MODE=marathon -e MARATHON_HOST=http://hostname:8080 pacesys/depcon

Environment File

$ vi myenv
DEPCON_MODE=marathon
MARATHON_HOST=http://hostname:8080
MARATHON_USER=someuser
MARATHON_PASS=pass

$ docker run --env-file=myenv pacesys/depcon app list

Using an existing depcon environment config.json

docker run -v $HOME/.depcon:/root/.depcon pacesys/depcon

Alternative: Using docker depcon like any other binary

# Run depcon in the background capture cid, add alias
$ cid=$(docker run -itd -v $PWD:/data pacesys/depcon)
$ alias depcon="docker exec -it ${cid} depcon"

# Use depcon like it was native
$ depcon app list
$ depcon app create /data/something.yml 
$ .... etc

Deploying to Marathon

This quick tutorial assumes you've read the docs on http://github.com/gondor/depcon. Lets assume we have a deployment descriptor we want to deploy called frontend-apache.yml . In summary we need to map the directory this file is into the container.

For this exercise lets assume the frontend-apache.yml descriptor is in the current host directory

docker run -v $PWD:/data --env-file=myenv pacesys/depcon app create /data/frontend-apache.yml

Source

Visit the Github repository for additional documentation and info at: https://github.com/gondor/depcon

Docker Pull Command
Owner
pacesys

Comments (0)