-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yaml
74 lines (72 loc) · 2.04 KB
/
docker-compose.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
version: '3.5'
services:
localstack:
image: localstack/localstack-light
ports:
- 4572:4572
- 8082:8082
environment:
SERVICES: 's3:4572'
PORT_WEB_UI: '8082'
DATA_DIR: /tmp/localstack/data
volumes:
- localstack:/tmp/localstack
- ./conf/localstack/init.sh:/docker-entrypoint-initaws.d/init.sh
db:
image: postgres:latest
ports:
- 5432:5432
environment:
POSTGRES_DB: hive
POSTGRES_USER: hive
POSTGRES_PASSWORD: hivesecret
volumes:
- postgres:/var/lib/postgresql/data
hive-metastore:
build:
context: ./images
dockerfile: Dockerfile.hive
restart: on-failure
volumes:
- ./conf/hive/hive-site.xml:/opt/hive/conf/hive-site.xml
- ./conf/hive/hivemetastore-site.xml:/opt/hive/conf/hivemetastore-site.xml
spark-master:
build:
context: ./images
dockerfile: Dockerfile.spark
restart: on-failure
ports:
- 8080:8080
environment:
SPARK_ROLE: master
volumes:
- ./conf/spark/hive-site.xml:/opt/spark/conf/hive-site.xml
- ./conf/spark/log4j.properties:/opt/spark/conf/log4j.properties
- ./conf/spark/spark-defaults.conf:/opt/spark/conf/spark-defaults.conf
spark-worker:
build:
context: ./images
dockerfile: Dockerfile.spark
restart: on-failure
environment:
SPARK_ROLE: worker
SPARK_MASTER_HOST: spark-master
volumes:
- ./conf/spark/hive-site.xml:/opt/spark/conf/hive-site.xml
- ./conf/spark/log4j.properties:/opt/spark/conf/log4j.properties
- ./conf/spark/spark-defaults.conf:/opt/spark/conf/spark-defaults.conf
spark-edge:
build:
context: ./images
dockerfile: Dockerfile.spark
environment:
SPARK_ROLE: edge
SPARK_MASTER_HOST: spark-master
volumes:
- ./conf/spark/hive-site.xml:/opt/spark/conf/hive-site.xml
- ./conf/spark/log4j.properties:/opt/spark/conf/log4j.properties
- ./conf/spark/spark-defaults.conf:/opt/spark/conf/spark-defaults.conf
- "${SOURCE_DIR}:/opt/spark/src"
volumes:
localstack: {}
postgres: {}