bentebbutt commited on
Commit
4464acc
1 Parent(s): 755e097

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -11
Dockerfile CHANGED
@@ -1,8 +1,8 @@
1
  FROM nikolaik/python-nodejs:python3.11-nodejs21
2
 
3
- # Install nginx, netcat-openbsd, and lsof
4
  USER root
5
- RUN apt-get -y update && apt-get -y install nginx netcat-openbsd lsof
6
 
7
  # Setup directory structure for Nginx
8
  RUN mkdir -p /var/cache/nginx \
@@ -29,9 +29,6 @@ RUN curl -fsSL https://ollama.com/install.sh | sh
29
  RUN mkdir -p /.ollama && chmod 777 /.ollama
30
  WORKDIR /.ollama
31
 
32
- # Set the OLLAMA_HOST environment variable
33
- ENV OLLAMA_HOST=0.0.0.0
34
-
35
  # Switch back to the 'pn' user for installing dependencies and building the app
36
  USER pn
37
  ENV HOME=/home/pn \
@@ -55,14 +52,12 @@ COPY --chown=pn backend backend
55
  COPY --chown=pn nginx.conf /etc/nginx/sites-available/default
56
  RUN ls -a
57
 
58
- # Prepare the entrypoint scripts
59
- COPY --chown=pn start_ollama.sh start_ollama.sh
60
- COPY --chown=pn start_app.sh start_app.sh
61
  RUN ls -a
62
- RUN chmod +x start_ollama.sh
63
- RUN chmod +x start_app.sh
64
 
65
  # Expose the port 11434 for ollama, 8080 for the backend, and 8000 for FastAPI
66
  EXPOSE 11434 8080 8000
67
 
68
- CMD ["bash", "start_ollama.sh"]
 
1
  FROM nikolaik/python-nodejs:python3.11-nodejs21
2
 
3
+ # Install nginx
4
  USER root
5
+ RUN apt-get -y update && apt-get -y install nginx
6
 
7
  # Setup directory structure for Nginx
8
  RUN mkdir -p /var/cache/nginx \
 
29
  RUN mkdir -p /.ollama && chmod 777 /.ollama
30
  WORKDIR /.ollama
31
 
 
 
 
32
  # Switch back to the 'pn' user for installing dependencies and building the app
33
  USER pn
34
  ENV HOME=/home/pn \
 
52
  COPY --chown=pn nginx.conf /etc/nginx/sites-available/default
53
  RUN ls -a
54
 
55
+ # Prepare the entrypoint script
56
+ COPY --chown=pn run.sh run.sh
 
57
  RUN ls -a
58
+ RUN chmod +x run.sh
 
59
 
60
  # Expose the port 11434 for ollama, 8080 for the backend, and 8000 for FastAPI
61
  EXPOSE 11434 8080 8000
62
 
63
+ CMD ["bash", "run.sh"]