Spaces:
Runtime error
Runtime error
added resource files
Browse files- Dockerfile +3 -1
- docker/Dockerfile +4 -4
- docker/run_voila +2 -1
Dockerfile
CHANGED
@@ -34,6 +34,8 @@ COPY --from=builder /home/jovyan/.local/ /home/jovyan/.local
|
|
34 |
COPY notebooks .
|
35 |
COPY docker/run_voila .
|
36 |
|
|
|
|
|
37 |
USER root
|
38 |
EXPOSE 7860
|
39 |
ENV PYTHONPATH "/home/jovyan/work/"
|
@@ -47,4 +49,4 @@ RUN jupyter nbextension enable --py --sys-prefix widgetsnbextension \
|
|
47 |
&& jupyter nbextension enable --py --sys-prefix ipysheet \
|
48 |
&& jupyter nbextension enable --py --sys-prefix voila
|
49 |
|
50 |
-
CMD ["bash", "-c", "nohup
|
|
|
34 |
COPY notebooks .
|
35 |
COPY docker/run_voila .
|
36 |
|
37 |
+
RUN chmod +x ./run_voila
|
38 |
+
|
39 |
USER root
|
40 |
EXPOSE 7860
|
41 |
ENV PYTHONPATH "/home/jovyan/work/"
|
|
|
49 |
&& jupyter nbextension enable --py --sys-prefix ipysheet \
|
50 |
&& jupyter nbextension enable --py --sys-prefix voila
|
51 |
|
52 |
+
CMD ["bash", "-c", "nohup python3 -m voila --enable_nbextensions=True --autoreload=True --no-browser --MappingKernelManager.cull_interval=60 --MappingKernelManager.cull_idle_timeout=120 --VoilaConfiguration.token='' & jupyter notebook --ip=0.0.0.0 --port=7860 --no-browser --allow-root --NotebookApp.token='huggingface' --NotebookApp.max_buffer_size=5368709120 --NotebookApp.tornado_settings=\"{'headers': {'Content-Security-Policy': 'frame-ancestors *'}}\" --NotebookApp.cookie_options=\"{'SameSite': 'None', 'Secure': True}\" --NotebookApp.disable_check_xsrf=True"]
|
docker/Dockerfile
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
##################
|
2 |
# Building Stage #
|
3 |
##################
|
4 |
-
FROM jupyter/base-notebook AS builder
|
5 |
|
6 |
COPY requirements.txt .
|
7 |
|
@@ -12,7 +12,7 @@ RUN python3 -m pip install --user --no-cache-dir --upgrade pip && \
|
|
12 |
#################
|
13 |
# Running Stage #
|
14 |
#################
|
15 |
-
FROM jupyter/base-notebook AS run
|
16 |
|
17 |
# Copy installed python packages (they are installed in that directory)
|
18 |
COPY --from=builder /home/jovyan/.local/ /home/jovyan/.local
|
@@ -27,7 +27,7 @@ RUN jupyter nbextension enable --py --sys-prefix widgetsnbextension
|
|
27 |
####################
|
28 |
# Deployment Stage #
|
29 |
####################
|
30 |
-
FROM jupyter/base-notebook AS deploy
|
31 |
|
32 |
# Copy installed python packages (they are installed in that directory)
|
33 |
COPY --from=builder /home/jovyan/.local/ /home/jovyan/.local
|
@@ -47,4 +47,4 @@ RUN jupyter nbextension enable --py --sys-prefix widgetsnbextension \
|
|
47 |
&& jupyter nbextension enable --py --sys-prefix ipysheet \
|
48 |
&& jupyter nbextension enable --py --sys-prefix voila
|
49 |
|
50 |
-
CMD ["bash", "-c", "nohup ./run_voila & jupyter notebook --ip=0.0.0.0 --port=7860 --no-browser --allow-root --NotebookApp.token='huggingface' --NotebookApp.tornado_settings=\"{'headers': {'Content-Security-Policy': 'frame-ancestors *'}}\" --NotebookApp.cookie_options=\"{'SameSite': 'None', 'Secure': True}\" --NotebookApp.disable_check_xsrf=True"]
|
|
|
1 |
##################
|
2 |
# Building Stage #
|
3 |
##################
|
4 |
+
FROM jupyter/base-notebook:python-3.10.11 AS builder
|
5 |
|
6 |
COPY requirements.txt .
|
7 |
|
|
|
12 |
#################
|
13 |
# Running Stage #
|
14 |
#################
|
15 |
+
FROM jupyter/base-notebook:python-3.10.11 AS run
|
16 |
|
17 |
# Copy installed python packages (they are installed in that directory)
|
18 |
COPY --from=builder /home/jovyan/.local/ /home/jovyan/.local
|
|
|
27 |
####################
|
28 |
# Deployment Stage #
|
29 |
####################
|
30 |
+
FROM jupyter/base-notebook:python-3.10.11 AS deploy
|
31 |
|
32 |
# Copy installed python packages (they are installed in that directory)
|
33 |
COPY --from=builder /home/jovyan/.local/ /home/jovyan/.local
|
|
|
47 |
&& jupyter nbextension enable --py --sys-prefix ipysheet \
|
48 |
&& jupyter nbextension enable --py --sys-prefix voila
|
49 |
|
50 |
+
CMD ["bash", "-c", "nohup ./run_voila & jupyter notebook --ip=0.0.0.0 --port=7860 --no-browser --allow-root --NotebookApp.token='huggingface' --NotebookApp.max_buffer_size=5368709120 --NotebookApp.tornado_settings=\"{'headers': {'Content-Security-Policy': 'frame-ancestors *'}}\" --NotebookApp.cookie_options=\"{'SameSite': 'None', 'Secure': True}\" --NotebookApp.disable_check_xsrf=True"]
|
docker/run_voila
CHANGED
@@ -4,4 +4,5 @@ python3 -m voila \
|
|
4 |
--autoreload=True \
|
5 |
--no-browser \
|
6 |
--MappingKernelManager.cull_interval=60 \
|
7 |
-
--MappingKernelManager.cull_idle_timeout=120
|
|
|
|
4 |
--autoreload=True \
|
5 |
--no-browser \
|
6 |
--MappingKernelManager.cull_interval=60 \
|
7 |
+
--MappingKernelManager.cull_idle_timeout=120 \
|
8 |
+
--VoilaConfiguration.token=''
|