Giter Site home page Giter Site logo

storm-mono-docker's Introduction

storm-mono-docker

Dockerfiles for building a storm cluster. Inspired by https://github.com/ptgoetz/storm-vagrant

The images are available directly from https://index.docker.io

Pre-Requisites

Usage

Start a cluster:

  • docker-compose up -d

  • The docker-compose up command aggregates the output of each container. When the command exits, all containers are stopped. Running docker-compose up -d starts the containers in the background and leaves them running.

Destroy a cluster:

  • docker-compose stop

Add more supervisors:

  • docker-compose scale supervisor=4

Kill and rm all docker cache:

  • docker kill $(docker ps -a -f "name=stormmonodocker" -q) ; docker rm $(docker ps -a -f "name=stormmonodocker" -q)

Remove all docker image:

  • docker rmi $(docker images | grep "^ziyunhx" | awk "{print $3}")

Building

  • rebuild.sh

FAQ

How can I access Storm UI from my host?

Take a look at docker-compose.yml:

ui:
  image: ziyunhx/storm-ui
      ports:
        - "49080:8080"

This tells Docker to expose the Docker UI container's port 8080 as port 49080 on the host

If you are running docker natively you can use localhost. If you're using boot2docker, then do:

$ boot2docker ip
The VM's Host only interface IP address is: 192.168.59.103

Which returns your docker VM's IP.
So, to open storm UI, type the following in your browser:

localhost:49080

or

192.168.59.103:49080

in my case.

How can I deploy a topology?

Since the nimbus host and port are not default, you need to specify where the nimbus host is, and what is the nimbus port number.
Following the example above, after discovering the nimbus host IP (could be localhost, could be our docker VM ip as in the case of boot2docker), run the following command:

storm jar target/your-topology-fat-jar.jar com.your.package.AndTopology topology-name -c nimbus.host=192.168.59.103 -c nimbus.thrift.port=49627

If the above method is not successful, please change the storm.yaml file like this:

nimbus.seeds: ["192.168.59.103"]	
nimbus.thrift.port: 49627

And run the following command:

storm jar target/your-topology-fat-jar.jar com.your.package.AndTopology topology-name

How can I connect to one of the containers?

Find the forwarded ssh port for the container you wish to connect to (use docker-compose ps)

$ ssh root@`boot2docker ip` -p $CONTAINER_PORT

The password is 'ziyunhxpass' (from: https://registry.hub.docker.com/u/ziyunhx/base/dockerfile/).

storm-mono-docker's People

Contributors

ziyunhx avatar lewischen1123 avatar

Stargazers

liqi avatar vulcangz avatar  avatar  avatar Wan Yu avatar PS avatar  avatar 看山 avatar Jintai Liu avatar fcym avatar RaoraoXiong avatar  avatar  avatar  avatar  avatar Kong De Qing avatar peng wei avatar guojiawei avatar zhaolu avatar rongkang avatar  avatar  avatar davidwei_001 avatar  avatar  avatar zhaohua avatar Wu Yongfeng avatar CHEN Kan avatar madfrog avatar  avatar  avatar

Watchers

davidwei_001 avatar  avatar  avatar  avatar

storm-mono-docker's Issues

creating stormmonodocker_supervisor_1 error

when I run

docker-compose up -d

appears errors like this:

Creating stormmonodocker_supervisor_1
ERROR: for supervisor UnixHTTPConnectionPool(host='localhost', port=None): Read timed out. (read timeout=60)
ERROR: for ui UnixHTTPConnectionPool(host='localhost', port=None): Read timed out. (read timeout=60)
Traceback (most recent call last):
File "/usr/bin/docker-compose", line 9, in
load_entry_point('docker-compose==1.8.0', 'console_scripts', 'docker-compose')()
File "/usr/lib/python2.7/site-packages/compose/cli/main.py", line 61, in main
command()
File "/usr/lib/python2.7/site-packages/compose/cli/main.py", line 113, in perform_command
handler(command, command_options)
File "/usr/lib/python2.7/contextlib.py", line 35, in exit
self.gen.throw(type, value, traceback)
File "/usr/lib/python2.7/site-packages/compose/cli/errors.py", line 56, in handle_connection_errors
log_timeout_error()
TypeError: log_timeout_error() takes exactly 1 argument (0 given)

docker-compose version
docker-compose version 1.8.0, build f3628c7
docker-py version: 1.9.0
CPython version: 2.7.12
OpenSSL version: OpenSSL 1.0.2h 3 May 2016
please give me some suggest to resolve the problem,thank you !

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.