| ################################################################################ |
| # Licensed to the Apache Software Foundation (ASF) under one |
| # or more contributor license agreements. See the NOTICE file |
| # distributed with this work for additional information |
| # regarding copyright ownership. The ASF licenses this file |
| # to you under the Apache License, Version 2.0 (the |
| # "License"); you may not use this file except in compliance |
| # with the License. You may obtain a copy of the License at |
| # |
| # http://www.apache.org/licenses/LICENSE-2.0 |
| # |
| # Unless required by applicable law or agreed to in writing, software |
| # distributed under the License is distributed on an "AS IS" BASIS, |
| # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| # See the License for the specific language governing permissions and |
| # limitations under the License. |
| ################################################################################ |
| |
| version: '2.1' |
| services: |
| jobmanager: |
| build: . |
| image: pyflink/pyflink:1.11.0-scala_2.11 |
| volumes: |
| - .:/opt/pyflink-walkthrough |
| hostname: "jobmanager" |
| expose: |
| - "6123" |
| ports: |
| - "8081:8081" |
| command: jobmanager |
| environment: |
| - JOB_MANAGER_RPC_ADDRESS=jobmanager |
| taskmanager: |
| image: pyflink/pyflink:1.11.0-scala_2.11 |
| volumes: |
| - .:/opt/pyflink-walkthrough |
| expose: |
| - "6121" |
| - "6122" |
| depends_on: |
| - jobmanager |
| command: taskmanager |
| links: |
| - jobmanager:jobmanager |
| environment: |
| - JOB_MANAGER_RPC_ADDRESS=jobmanager |
| zookeeper: |
| image: wurstmeister/zookeeper:3.4.6 |
| ports: |
| - "2181:2181" |
| kafka: |
| image: wurstmeister/kafka:2.12-2.2.1 |
| ports: |
| - "9092" |
| depends_on: |
| - zookeeper |
| environment: |
| HOSTNAME_COMMAND: "route -n | awk '/UG[ \t]/{print $$2}'" |
| KAFKA_ZOOKEEPER_CONNECT: zookeeper:2181 |
| KAFKA_CREATE_TOPICS: "payment_msg:1:1" |
| volumes: |
| - /var/run/docker.sock:/var/run/docker.sock |
| generator: |
| build: generator |
| image: generator:1.0 |
| depends_on: |
| - kafka |
| elasticsearch: |
| image: docker.elastic.co/elasticsearch/elasticsearch:7.8.0 |
| environment: |
| - cluster.name=docker-cluster |
| - bootstrap.memory_lock=true |
| - "ES_JAVA_OPTS=-Xms512m -Xmx512m" |
| - discovery.type=single-node |
| ports: |
| - "9200:9200" |
| - "9300:9300" |
| ulimits: |
| memlock: |
| soft: -1 |
| hard: -1 |
| nofile: |
| soft: 65536 |
| hard: 65536 |
| kibana: |
| image: docker.elastic.co/kibana/kibana:7.8.0 |
| ports: |
| - "5601:5601" |
| depends_on: |
| - elasticsearch |
| load-kibana-dashboard: |
| build: ./kibana |
| command: ['/bin/bash', '-c', 'cat /tmp/load/load_ndjson.sh | tr -d "\r" | bash'] |
| depends_on: |
| - kibana |