NitinBot002 commited on
Commit
1083646
·
verified ·
1 Parent(s): 83e6f13

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +11 -3
Dockerfile CHANGED
@@ -11,6 +11,12 @@ RUN apt-get update && apt-get install -y \
11
  npm \
12
  && rm -rf /var/lib/apt/lists/*
13
 
 
 
 
 
 
 
14
  # Set working directory
15
  WORKDIR /app
16
 
@@ -21,8 +27,10 @@ RUN pip install --no-cache-dir -r requirements.txt
21
  # Copy application files
22
  COPY . .
23
 
24
- # Create workspace directory
25
- RUN mkdir -p /tmp/workspace
 
 
26
 
27
  # Expose ports
28
  EXPOSE 7860 8080
@@ -32,4 +40,4 @@ ENV PORT=7860
32
  ENV CODE_SERVER_PASSWORD=huggingface123
33
 
34
  # Run the application
35
- CMD ["python", "app.py"]
 
11
  npm \
12
  && rm -rf /var/lib/apt/lists/*
13
 
14
+ # Install code-server
15
+ RUN curl -fsSL https://code-server.dev/install.sh | sh
16
+
17
+ # Verify code-server installation
18
+ RUN code-server --version
19
+
20
  # Set working directory
21
  WORKDIR /app
22
 
 
27
  # Copy application files
28
  COPY . .
29
 
30
+ # Create workspace directory and set permissions
31
+ RUN mkdir -p /tmp/workspace && \
32
+ mkdir -p /root/.config/code-server && \
33
+ chmod -R 755 /tmp/workspace
34
 
35
  # Expose ports
36
  EXPOSE 7860 8080
 
40
  ENV CODE_SERVER_PASSWORD=huggingface123
41
 
42
  # Run the application
43
+ CMD ["python", "app.py"]