Forked from narayandesai/gist:5de29170207396c98108
Last active
August 29, 2015 14:04
Revisions
-
bennofs revised this gist
Jul 29, 2014 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -6,7 +6,7 @@ stdenv.mkDerivation rec { unpackPhase = "true"; installPhase = '' set -x mkdir -p $out/bin @@ -28,5 +28,5 @@ installPhase = " EOF chmod +x $out/bin/mesos-spark-shell ''; } -
narayandesai created this gist
Jul 29, 2014 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,32 @@ {stdenv, bash, jre, spark} : stdenv.mkDerivation rec { name = "mesos-spark-${version}"; version = "1"; unpackPhase = "true"; installPhase = " set -x mkdir -p $out/bin cat > $out/bin/mesos-spark-shell <<EOF #!${bash}/bin/bash set -o posix export JAVA_HOME=${jre} export SPARK_HOME=${spark}/lib/spark-1.0.1-bin-cdh4 for o in "\$@"; do if [ "\$1" = "-c" -o "\$1" = "--cores" ]; then shift if [ -n "\$1" ]; then OPTIONS="-Dspark.cores.max=\$1" shift fi fi done EOF chmod +x $out/bin/mesos-spark-shell "; }