Skip to content

Docker image with spark and mesos installed. Used for driving spark on mesos cluster with docker.

Notifications You must be signed in to change notification settings

wangqiang8511/docker-spark-mesos

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Spark Docker for Mesos (DCOS)

Docker image for running spark with mesos (DCOS). Build with

How to use

Build Image

make docker-build

Pull Image

make docker-pull

Start spark driver inside docker container

MESOS_IP=mesos://<ip>:<port>
EXECUTOR_IMAGE=dmitryb/mesos-spark:2.1.1
CORES=2
RAM=2g

docker run -it --rm --net=host dmitryb/mesos-spark:2.1.1 bash /opt/spark/bin/spark-shell \
    --conf spark.master=${MESOS_IP} \
    --conf spark.driver.host=${DRIVER_IP} \
    --conf spark.mesos.coarse=true \
    --conf spark.mesos.executor.docker.image=${EXECUTOR_IMAGE} \
    --conf spark.mesos.executor.home=/opt/spark \
    --conf spark.task.maxFailures=10 \
    --conf spark.sql.parquet.compression.codec=gzip \
    --conf spark.sql.warehouse.dir=file:///tmp \
    --conf spark.serializer=org.apache.spark.serializer.KryoSerializer \
    --conf spark.kryoserializer.buffer.max=1g \
    --conf spark.task.cpus=1 \
    --conf spark.executor.memory=${RAM} \
    --conf spark.cores.max=${CORES} \
    --conf spark.sql.shuffle.partitions=2000 \
    --conf spark.shuffle.spill=true \
    --conf spark.executor.heartbeatInterval=10

TODO

Integrate with pyspark

About

Docker image with spark and mesos installed. Used for driving spark on mesos cluster with docker.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published