GithubHelp home page GithubHelp logo

pombredanne / dockerboot Goto Github PK

View Code? Open in Web Editor NEW

This project forked from samalba/dockerboot

0.0 2.0 0.0 154 KB

Boot your machine with a fig.yml and docker

License: Apache License 2.0

Go 100.00%

dockerboot's Introduction

dockerboot

Boot your machine with a simple fig.yml file and docker.

How to use?

Install Golang and configure your GOPATH.

Then:

$ go get github.com/samalba/dockerboot
$ export PATH=$PATH:${GOPATH}/bin
$ dockerboot
Usage: dockerboot [OPTIONS] COMMAND

Options:
  -H="unix:///var/run/docker.sock": URL of the docker daemon
  -f="./fig.yml": Fig yaml file to read the services config from

Commands:
  start: Start all services and process configuration updates
  reload: Process configuration updates (alias to `start')
  stop: Stop all services
  restart: Restart all services and process configuration updates

Give me an example

Step 1: Write a `fig.yml' file that contains the services you want to boot your system with.

Note: this example will do nothing but start containers...

web:
  image: ubuntu:14.04
  command: cat
  ports:
   - "8000:8000"
db:
  image: busybox
  command: cat

Step 2: Start the services using dockerboot.

$ ./dockerboot start
2015/02/28 17:57:08 main.Config{FigFile:"./fig.yml", DockerUrl:"unix:///var/run/docker.sock"}
2015/02/28 17:57:09 Discovered possible existing services: web, db, foo, bar, test2, test1, test, furious_galileo
2015/02/28 17:57:09 Service `web' does not change
2015/02/28 17:57:09 Starting service `web'...
2015/02/28 17:57:09 Service `db' does not change
2015/02/28 17:57:09 Starting service `db'...

Step 3: You can still use `docker' directly for everything else.

$ docker ps
CONTAINER ID        IMAGE               COMMAND             CREATED             STATUS              PORTS               NAMES
1e733ffc9162        ubuntu:14.04        "cat"               12 days ago         Up 24 minutes       8000/tcp            web
f5e1f4817064        busybox:latest      "cat"               12 days ago         Up 24 minutes                           db

dockerboot's People

Contributors

samalba avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.