You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by foxish <gi...@git.apache.org> on 2018/06/25 19:01:37 UTC
[GitHub] spark pull request #21279: [SPARK-24219][k8s] Improve the docker building sc...
Github user foxish commented on a diff in the pull request:
https://github.com/apache/spark/pull/21279#discussion_r197906642
--- Diff: bin/docker-image-tool.sh ---
@@ -44,15 +44,37 @@ function image_ref {
function build {
local BUILD_ARGS
local IMG_PATH
+ local TMPFOLDER
if [ ! -f "$SPARK_HOME/RELEASE" ]; then
# Set image build arguments accordingly if this is a source repo and not a distribution archive.
+ local JARS="${SPARK_HOME}/assembly/target/scala-${SPARK_SCALA_VERSION}/jars"
+ TMPFOLDER=`mktemp -q -d examples.XXXXXX`
+ if [ $? -ne 0 ]; then
+ ehco "Cannot create temp folder, exiting..."
+ exit 1
+ fi
+
+ mkdir -p "${TMPFOLDER}/jars"
+ cp "${SPARK_HOME}"/examples/target/scala*/jars/* "${TMPFOLDER}/jars"
--- End diff --
Do we need the temp folder? Can we just pass the path `"${SPARK_HOME}"/examples/target/scala*/jars/*` to the dockerfile instead to pick up?
---
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org