Collection of Apache Spark docker images for OKDP Platform.
Currently, the images are built from the Apache Spark project distribution and the requirement may evolve to produce them from the source code.
The image relashionship is described by the following diagram:
Image | Description |
---|---|
JRE |
The JRE LTS base image supported by Apache Spark depending on the version. This includes Java 11/17/21. Please, check the reference versions or Apache Spark website for more information. |
spark-base |
The Apache Spark base image with official spark binaries (scala/java) and without OKDP extensions. |
spark |
The Apache Spark image with official spark binaries (scala/java) and OKDP extensions. |
spark-py |
The Apache Spark image with official spark binaries (scala/java), OKDP extensions and python support. |
spark-r |
The Apache Spark image with official spark binaries (scala/java), OKDP extensions and R support. |
The project builds the images with a long format tags. Each tag combines multiple compatible versions combinations.
There are multiple tags levels and the format to use depends on your convenience in term of stability and reproducibility.
The images are pushed to quay.io/okdp repository with the following tags:
Images | Tags |
---|---|
spark-base, spark | spark-<SPARK_VERSION>-scala-<SCALA_VERSION>-java-<JAVA_VERSION> spark-<SPARK_VERSION>-scala-<SCALA_VERSION>-java-<JAVA_VERSION>-<BUILD_DATE> spark-<SPARK_VERSION>-scala-<SCALA_VERSION>-java-<JAVA_VERSION>-<RELEASE_VERSION> spark-<SPARK_VERSION>-scala-<SCALA_VERSION>-java-<JAVA_VERSION>-<BUILD_DATE>-<RELEASE_VERSION> |
spark-py | spark-<SPARK_VERSION>-python-<PYTHON_VERSION>-scala-<SCALA_VERSION>-java-<JAVA_VERSION> spark-<SPARK_VERSION>-python-<PYTHON_VERSION>-scala-<SCALA_VERSION>-java-<JAVA_VERSION>-<BUILD_DATE> spark-<SPARK_VERSION>-python-<PYTHON_VERSION>-scala-<SCALA_VERSION>-java-<JAVA_VERSION>-<RELEASE_VERSION> spark-<SPARK_VERSION>-python-<PYTHON_VERSION>-scala-<SCALA_VERSION>-java-<JAVA_VERSION>-<BUILD_DATE>-<RELEASE_VERSION> |
spark-r | spark-<SPARK_VERSION>-r-<R_VERSION>-scala-<SCALA_VERSION>-java-<JAVA_VERSION> spark-<SPARK_VERSION>-r-<R_VERSION>-scala-<SCALA_VERSION>-java-<JAVA_VERSION>-<BUILD_DATE> spark-<SPARK_VERSION>-r-<R_VERSION>-scala-<SCALA_VERSION>-java-<JAVA_VERSION>-<RELEASE_VERSION> spark-<SPARK_VERSION>-r-<R_VERSION>-scala-<SCALA_VERSION>-java-<JAVA_VERSION>-<BUILD_DATE>-<RELEASE_VERSION> |
Note
-
<RELEASE_VERSION>
corresponds to the Github release version or git tag without the leadingv
. Ex.: 1.0.0 -
<BUILD_DATE>
corresponds to the images build date with theYYYY-MM-DD
format. The latest release tag is rebuilt every week to ensure the OS image is up to date against the latest security updates.You may need to switch to the latest release version if your are using the long form tag image with a
<RELEASE_VERSION>
. Please, check the changelog to see the notable impacts.An example of
py-spark
image with a long form tag includingspark/java/scala/python
compatible versions and a<BUILD_DATE>
with a<RELEASE_VERSION>
is:quay.io/okdp/spark-py:spark-3.5.1-python-3.11-scala-2.13-java-17-2024-04-04-1.0.0
.The corresponding changelog is releases/tag/v1.0.0.
-
You can also use the latest tag without
<BUILD_DATE>
and<RELEASE_VERSION>
which is always up to date with the latest security updates.An example of
py-spark
image with the latest tag is:quay.io/okdp/spark-py:spark-3.5.1-python-3.11-scala-2.13-java-17
This project automatically applies security fixes and dependency updates to Spark source code during builds using a patch and pombump system.
Key Features:
- ✅ Source code patches for critical security fixes
- ✅ Automated dependency updates via pombump
- ✅ Version-specific configurations
- ✅ Build optimization and compatibility
The system uses .build/pre-build-patch-pombump.yml
to determine which Spark versions should receive patches and/or dependency updates:
controls:
- spark_version: "3.4.1"
python_version: "3.11"
java_version: "17"
hadoop_version: "3.3.6"
patch_files: [] # No source patches needed, but pombump will run
If a Spark version is present in the configuration file:
- Source Download: The system downloads the Spark source code
- Patch Application: Applies any source code patches (if
patch_files
is not empty) - Dependency Updates: Runs pombump to update Maven dependencies to secure versions
- Build Context: Uses the patched/updated source for Docker builds
If a Spark version is not in the configuration:
- Uses original Spark distribution without modifications
For versions in the configuration, pombump automatically updates dependencies to secure versions:
# From pombump-properties.yaml
- property: log4j.version
value: "2.25.0" # Updates to secure Log4j version
- property: fasterxml.jackson.version
value: "2.14.2" # Updates Jackson for security
This ensures all builds use the latest secure dependency versions, even without source code changes.
📖 Read the full patching documentation →
Quick Reference:
- Patch configuration:
.build/pre-build-patch-pombump.yml
- Patch files:
spark-base/spark-X.Y/
- Application logic:
.github/actions/patch-pombump/