File size: 916 Bytes
916bcca
6992e29
 
 
 
 
 
 
 
 
916bcca
6992e29
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
916bcca
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
FROM docker.io/library/nginx:latest
# Set the working directory to /app
WORKDIR /app

# Copy the requirements file
COPY requirements.txt .

COPY public /app/public

# Install the dependencies
RUN apt-get update && apt-get install -y wget && pip install -r requirements.txt
# Copy the JupyterLab configuration file
COPY jupyter_config.py /etc/jupyterlab/jupyter_config.py

# Expose the port 8888 for JupyterLab (no se utiliza, solo para referencia)
EXPOSE 8888

# Set the environment variables
ENV JUPYTERLAB_PORT=8888
ENV JUPYTERLAB_TOKEN=your_secret_token

# Run JupyterLab when the container starts
CMD ["jupyter", "lab", "--port", "8888", "--no-browser", "--allow-root"]

# Use Nginx as a reverse proxy
COPY nginx.conf /etc/nginx/nginx.conf

# Expose the port 7860 for Nginx
EXPOSE 7860

# Set the environment variables
ENV NGINX_PORT=7860

# Run Nginx when the container starts
CMD ["nginx", "-g", "daemon off;"]