Skip to content

Commit

Permalink
mlops: make kedro mandatory again
Browse files Browse the repository at this point in the history
disable kedro telemetry
  • Loading branch information
moss2k13 committed Sep 13, 2024
1 parent 5f7d25e commit 70643c5
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 11 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/build_mlops.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Build jupyterlab-mlops Image
env:
KEDRO_DEFAULT_VERSION: "NONE"
KEDRO_DEFAULT_VERSION: "0.19.8"
MLFLOW_DEFAULT_VERSION: "2.15.1"
VSCODE_DEFAULT_VERSION: "NONE"
PYTHON_DEFAULT_VERSION: "3.11"
Expand Down Expand Up @@ -50,6 +50,7 @@ jobs:
nb-user: jupyter
- base-image: "jupyter/minimal-notebook:python-3.11.6"
spark-support: false
kedro-version: "0.19.8"
mlflow-version: "2.15.1"
vscode-version: "4.91.1"
python-version: "3.11"
Expand Down
17 changes: 7 additions & 10 deletions jupyterlab-mlops/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ ENV NB_USER=$USER \
NB_GID=$GID \
CONDA_DIR=/opt/conda \
VSCODE_VERSION=$VSCODE_VERSION \
KEDRO_VERSION=$KEDRO_VERSION
KEDRO_VERSION=$KEDRO_VERSION \
KEDRO_DISABLE_TELEMETRY=true

USER root

Expand Down Expand Up @@ -106,16 +107,12 @@ RUN mamba install --quiet --yes kfp jupyter-server-proxy -c conda-forge && \
pip --no-cache-dir install mlflow==$MLFLOW_VERSION && \
mamba clean --all -f -y

# configure python env with optional kedro
RUN if [ "${KEDRO_VERSION}" != "NONE" ]; then \
mamba create --quiet --yes -p "${CONDA_DIR}/envs/python${PYTHON_VERSION}" python=${PYTHON_VERSION} ipython ipykernel kedro=${KEDRO_VERSION} && \
# configure python env with kedro
RUN mamba create --quiet --yes -p "${CONDA_DIR}/envs/python${PYTHON_VERSION}" \
python=${PYTHON_VERSION} ipython ipykernel kedro=${KEDRO_VERSION} kedro-viz && \
mamba clean --all -f -y && \
"${CONDA_DIR}/envs/python${PYTHON_VERSION}/bin/python" -m ipykernel install --user --name=python${PYTHON_VERSION}; \
else \
mamba create --quiet --yes -p "${CONDA_DIR}/envs/python${PYTHON_VERSION}" python=${PYTHON_VERSION} ipython ipykernel && \
mamba clean --all -f -y && \
"${CONDA_DIR}/envs/python${PYTHON_VERSION}/bin/python" -m ipykernel install --user --name=python${PYTHON_VERSION}; \
fi
"${CONDA_DIR}/envs/python${PYTHON_VERSION}/bin/python" -m ipykernel \
install --user --name=python${PYTHON_VERSION}

RUN fix-permissions "/home/${NB_USER}" && \
fix-permissions "${CONDA_DIR}" && \
Expand Down

0 comments on commit 70643c5

Please sign in to comment.