2020-08-17 08:49:50 +02:00
|
|
|
version: "3.8"
|
2019-09-28 07:06:26 +02:00
|
|
|
|
|
|
|
services:
|
|
|
|
|
|
|
|
coordinator:
|
2019-10-21 05:49:39 +02:00
|
|
|
image: vimagick/prestodb:alpine
|
2019-09-28 07:06:26 +02:00
|
|
|
ports:
|
|
|
|
- "8080:8080"
|
|
|
|
volumes:
|
|
|
|
- /data:/data
|
2019-10-21 05:36:26 +02:00
|
|
|
- prestodb_coordinator_conf:/opt/presto/etc
|
2019-09-28 07:06:26 +02:00
|
|
|
deploy:
|
|
|
|
replicas: 1
|
|
|
|
placement:
|
|
|
|
constraints:
|
|
|
|
- node.role == manager
|
|
|
|
restart_policy:
|
|
|
|
condition: on-failure
|
|
|
|
|
|
|
|
worker:
|
2019-10-21 05:49:39 +02:00
|
|
|
image: vimagick/prestodb:alpine
|
2019-10-21 16:02:39 +02:00
|
|
|
entrypoint: sh -c 'launcher run -Dnode.id=$$HOSTNAME'
|
2019-09-28 07:06:26 +02:00
|
|
|
volumes:
|
|
|
|
- /data:/data
|
2019-10-21 05:36:26 +02:00
|
|
|
- prestodb_worker_conf:/opt/presto/etc
|
2019-09-28 07:06:26 +02:00
|
|
|
deploy:
|
2020-08-17 08:49:50 +02:00
|
|
|
replicas: 3
|
2019-09-28 07:06:26 +02:00
|
|
|
placement:
|
|
|
|
constraints:
|
|
|
|
- node.role == worker
|
2020-08-17 08:49:50 +02:00
|
|
|
max_replicas_per_node: 1
|
2019-09-28 07:06:26 +02:00
|
|
|
restart_policy:
|
|
|
|
condition: on-failure
|
|
|
|
depends_on:
|
|
|
|
- coordinator
|
|
|
|
|
|
|
|
volumes:
|
|
|
|
|
2019-10-21 05:36:26 +02:00
|
|
|
prestodb_coordinator_conf:
|
2019-09-28 07:06:26 +02:00
|
|
|
driver: local
|
|
|
|
driver_opts:
|
|
|
|
type: nfs
|
|
|
|
o: "addr=10.0.0.1,nolock,soft,ro"
|
2019-10-21 05:36:26 +02:00
|
|
|
device: ":/export/prestodb/coordinator"
|
2019-09-28 07:06:26 +02:00
|
|
|
|
2019-10-21 05:36:26 +02:00
|
|
|
prestodb_worker_conf:
|
2019-09-28 07:06:26 +02:00
|
|
|
driver: local
|
|
|
|
driver_opts:
|
|
|
|
type: nfs
|
|
|
|
o: "addr=10.0.0.1,nolock,soft,ro"
|
2019-10-21 05:36:26 +02:00
|
|
|
device: ":/export/prestodb/worker"
|