Skip to content

Commit bf3ad5e

Browse files
authored
chore: update jupyterhub-pyspark demo with newer image and dependencies (#112)
* chore: update jupyterhub-pyspark demo with newer image and dependencies * linting * linting II * linting III * linting again * remove spaces in braces * deactivate the arm runner * renaming
1 parent c23acfc commit bf3ad5e

File tree

5 files changed

+14
-11
lines changed

5 files changed

+14
-11
lines changed

.github/workflows/dev_pyspark-k8s-with-scikit-learn.yaml .github/workflows/dev_spark-k8s-with-scikit-learn.yaml

+7-5
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
---
2-
name: Build and publish pyspark-k8s-with-scikit-learn
2+
name: Build and publish spark-k8s-with-scikit-learn
33

44
env:
5-
IMAGE_NAME: pyspark-k8s-with-scikit-learn
6-
IMAGE_VERSION: 3.4.0-stackable0.0.0-dev
5+
IMAGE_NAME: spark-k8s-with-scikit-learn
6+
IMAGE_VERSION: 3.5.0-stackable24.3.0
77
REGISTRY_PATH: stackable
88
DOCKERFILE_PATH: "demos/jupyterhub-pyspark-hdfs-anomaly-detection-taxi-data/Dockerfile"
99

@@ -15,7 +15,7 @@ on:
1515
paths:
1616
- demos/jupyterhub-pyspark-hdfs-anomaly-detection-taxi-data/Dockerfile
1717
- demos/jupyterhub-pyspark-hdfs-anomaly-detection-taxi-data/requirements.txt
18-
- .github/workflows/dev_pyspark-k8s-with-scikit-learn.yaml
18+
- .github/workflows/dev_spark-k8s-with-scikit-learn.yaml
1919

2020
jobs:
2121
build:
@@ -27,7 +27,9 @@ jobs:
2727
matrix:
2828
runner:
2929
- {name: "ubuntu-latest", arch: "amd64"}
30-
- {name: "ubicloud-standard-8-arm", arch: "arm64"}
30+
# TODO: the image 3.5.0-stackable24.3.0 does not have an arm64 build.
31+
# Re-activate the arm runner when the image is updated to one that does.
32+
#- {name: "ubicloud-standard-8-arm", arch: "arm64"}
3133
steps:
3234
- name: Checkout Repository
3335
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7

demos/jupyterhub-pyspark-hdfs-anomaly-detection-taxi-data/Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM docker.stackable.tech/stackable/spark-k8s:3.5.1-stackable24.7.0
1+
FROM docker.stackable.tech/stackable/spark-k8s:3.5.0-stackable24.3.0
22

33
COPY demos/jupyterhub-pyspark-hdfs-anomaly-detection-taxi-data/requirements.txt .
44

Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
scikit-learn==1.1.3
2-
pandas==1.5.1
1+
scikit-learn==1.3.1
2+
pandas==2.0.3

stacks/_templates/jupyterhub.yaml

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
---
12
releaseName: jupyterhub
23
name: jupyterhub
34
repo:
@@ -11,7 +12,7 @@ options:
1112
allowed_users:
1213
- admin
1314
DummyAuthenticator:
14-
password: {{ jupyterHubAdminPassword }}
15+
password: {{jupyterHubAdminPassword}}
1516
JupyterHub:
1617
authenticator_class: dummy
1718
labels:
@@ -39,7 +40,7 @@ options:
3940
# Inspect the Dockerfile at:
4041
# https://github.com/jupyter/docker-stacks/tree/HEAD/datascience-notebook/Dockerfile
4142
name: jupyter/pyspark-notebook
42-
tag: python-3.9
43+
tag: python-3.11
4344
serviceAccountName: spark
4445
networkPolicy:
4546
enabled: false

stacks/jupyterhub-pyspark-hdfs/notebook.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
"spark = (SparkSession\n",
3535
" .builder\n",
3636
" .master(f'k8s://https://{os.environ[\"KUBERNETES_SERVICE_HOST\"]}:{os.environ[\"KUBERNETES_SERVICE_PORT\"]}')\n",
37-
" .config(\"spark.kubernetes.container.image\", \"docker.stackable.tech/demos/pyspark-k8s-with-scikit-learn:3.3.0-stackable23.4\")\n",
37+
" .config(\"spark.kubernetes.container.image\", \"docker.stackable.tech/demos/spark-k8s-with-scikit-learn:3.5.0-stackable24.3.0\")\n",
3838
" .config(\"spark.driver.port\", \"2222\")\n",
3939
" .config(\"spark.driver.blockManager.port\", \"7777\")\n",
4040
" .config(\"spark.driver.host\", \"driver-service.default.svc.cluster.local\")\n",

0 commit comments

Comments
 (0)