美文网首页
swarmjstorm

swarmjstorm

作者: 运维经理 | 来源:发表于2018-02-06 12:21 被阅读0次

zk1:

    image: 'mesoscloud/zookeeper:3.4.8-ubuntu'

    environment:

        - MYID=1

        - SERVERS=${COMPOSE_PROJECT_NAME}_zk1_1,${COMPOSE_PROJECT_NAME}_zk2_1,${COMPOSE_PROJECT_NAME}_zk3_1

        - constraint:aliyun.node_index==1

    restart: 'always'

zk2:

    image: 'mesoscloud/zookeeper:3.4.8-ubuntu'

    environment:

        - MYID=2

        - SERVERS=${COMPOSE_PROJECT_NAME}_zk1_1,${COMPOSE_PROJECT_NAME}_zk2_1,${COMPOSE_PROJECT_NAME}_zk3_1

        - constraint:aliyun.node_index==2

    restart: 'always'

zk3:

    image: 'mesoscloud/zookeeper:3.4.8-ubuntu'

    environment:

        - MYID=3

        - SERVERS=${COMPOSE_PROJECT_NAME}_zk1_1,${COMPOSE_PROJECT_NAME}_zk2_1,${COMPOSE_PROJECT_NAME}_zk3_1

        - constraint:aliyun.node_index==3

    restart: 'always'

nimbus:

    image: 'registry.cn-hangzhou.aliyuncs.com/jstorm-docker/jstorm'

    environment:

        - CHARACTER=nimbus

        - ZK_ROOT=/jstorm.docker.root2

        - ZK_HOSTS=${COMPOSE_PROJECT_NAME}_zk1_1,${COMPOSE_PROJECT_NAME}_zk2_1,${COMPOSE_PROJECT_NAME}_zk3_1

        - CLUSTER_NAME=jstorm.docker.cluster

    labels:

        aliyun.routing.port_8080: 'http://nimbus'

        aliyun.scale: '2'

    restart: 'always'

    links:

        - zk1

        - zk2

        - zk3

supervisor:

    image: 'registry.cn-hangzhou.aliyuncs.com/jstorm-docker/jstorm'

    environment:

        - CHARACTER=supervisor

        - NIMBUS_HOSTS=jstorm_nimbus_1

        - ZK_ROOT=/jstorm.docker.root2

        - ZK_HOSTS=${COMPOSE_PROJECT_NAME}_zk1_1,${COMPOSE_PROJECT_NAME}_zk2_1,${COMPOSE_PROJECT_NAME}_zk3_1

        - CLUSTER_NAME=jstorm.docker.cluster

    labels:

        aliyun.routing.port_8080: 'http://supervisor'

        aliyun.scale: '3'

    restart: 'always'

    links:

        - nimbus

相关文章

  • swarmjstorm

    zk1: image: 'mesoscloud/zookeeper:3.4.8-ubuntu' envir...

网友评论

      本文标题:swarmjstorm

      本文链接:https://www.haomeiwen.com/subject/mckgzxtx.html