From 3eea499f900be7c6f6ffaaeca9832f38fb2e385e Mon Sep 17 00:00:00 2001 From: Tater Totterson Date: Fri, 26 Sep 2025 19:41:21 -0500 Subject: [PATCH] Add files via upload --- dockerfile | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/dockerfile b/dockerfile index c02cbc1..9a17d50 100644 --- a/dockerfile +++ b/dockerfile @@ -5,12 +5,12 @@ ENV DEBIAN_FRONTEND=noninteractive \ PYTHONUNBUFFERED=1 \ PIP_NO_CACHE_DIR=1 -# System deps +# System deps (+dev headers for building C/C++ extensions) RUN apt-get update && apt-get install -y --no-install-recommends \ - python3.10 python3.10-venv python3.10-distutils python3-pip \ + python3.10 python3.10-venv python3.10-distutils python3.10-dev python3-pip \ git wget curl unzip ca-certificates \ build-essential g++ cmake \ - libsndfile1 libffi-dev \ + libsndfile1 libsndfile1-dev libffi-dev \ && rm -rf /var/lib/apt/lists/* # Use python3.10 everywhere @@ -18,21 +18,24 @@ RUN update-alternatives --install /usr/bin/python python /usr/bin/python3.10 1 \ && update-alternatives --install /usr/bin/pip pip /usr/bin/pip3 1 # Python deps +# Pre-install numpy (and cython) so native builds (webrtcvad, pymicro_features) have headers ready COPY requirements.txt /tmp/requirements.txt -RUN pip install --upgrade pip && pip install -r /tmp/requirements.txt +RUN pip install --upgrade pip \ + && pip install "numpy==1.26.4" "cython>=0.29.36" \ + && pip install -r /tmp/requirements.txt # Workspace + notebook fallback RUN mkdir -p /data WORKDIR /data COPY microWakeWord_training_notebook.ipynb /root/ -# Startup script (copies default notebook if missing, then launches JupyterLab) +# Startup script (copies default notebook if missing) COPY startup.sh /usr/local/bin/startup.sh RUN chmod +x /usr/local/bin/startup.sh EXPOSE 8888 -# Launch Lab (tokenless for local dev; set a token if you want auth) +# Launch JupyterLab (tokenless for local dev; set a token if you want auth) CMD ["/bin/bash", "-lc", "/usr/local/bin/startup.sh && \ exec jupyter lab --ip=0.0.0.0 --port=8888 --no-browser --allow-root \ --ServerApp.token='' --ServerApp.password='' --ServerApp.root_dir=/data"] \ No newline at end of file