Commit ae1d743
committed
[SPARK-25957][K8S] Add ability to skip building optional k8s docker images
bin/docker-image-tool.sh tries to build all docker images (JVM, PySpark
and SparkR) by default. But not all spark distributions are built with
SparkR and hence this script will fail on such distros.
With this change,
- We should be able to skip building optional docker
images (PySpark and SparkR) by specifying -pskip or -Rskip flags.
- We autodetect if SparkR is not installed in the build and skip building
SparkR docker image.
- We skip pushing docker images that are not available locally.
Tested following scenarios.
- On source code and distro with SparkR support
- Run bin/docker-image-tool.sh -r <repo> -t <tag> build. Verify that JVM, PySpark and SparkR docker images are built.
- Run bin/docker-image-tool.sh -r <repo> -t <tag> -Rskip -pskip build. Verify that only JVM docker image is built. Building PySpark and SparkR images is skipped.
- On source code and distro without SparkR support
- Run bin/docker-image-tool.sh -r <repo> -t <tag> build. Verify that only JVM, PySpark docker images are built. Building SparkR image is skipped.
- On system with JVM, PySpark and SparkR images built,
- Run bin/docker-image-tool.sh -r <repo> -t <tag> push. Verify that all images are pushed to docker registry.
- On system with only JVM and PySpark images built.
- Run bin/docker-image-tool.sh -r <repo> -t <tag> push. Verify that only JVM and PySpark images are pushed. Pushing SparkR images is skipped.1 parent 9a5fda6 commit ae1d743
1 file changed
+35
-21
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
44 | 56 | | |
45 | 57 | | |
46 | 58 | | |
| |||
102 | 114 | | |
103 | 115 | | |
104 | 116 | | |
105 | | - | |
106 | | - | |
107 | | - | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
108 | 132 | | |
109 | | - | |
| 133 | + | |
110 | 134 | | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
| 135 | + | |
| 136 | + | |
116 | 137 | | |
117 | 138 | | |
118 | 139 | | |
119 | 140 | | |
120 | | - | |
121 | | - | |
122 | | - | |
123 | | - | |
124 | | - | |
125 | | - | |
126 | | - | |
127 | | - | |
128 | | - | |
129 | | - | |
130 | | - | |
131 | | - | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
132 | 144 | | |
133 | 145 | | |
134 | 146 | | |
| |||
145 | 157 | | |
146 | 158 | | |
147 | 159 | | |
| 160 | + | |
| 161 | + | |
148 | 162 | | |
149 | 163 | | |
150 | 164 | | |
| |||
0 commit comments