psyflowz commited on
Commit
d5340df
·
verified ·
1 Parent(s): 8b43870

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +2 -70
Dockerfile CHANGED
@@ -1,76 +1,8 @@
1
- FROM debian:bookworm-slim
2
-
3
- ENV DEBIAN_FRONTEND=noninteractive
4
- ENV PORT=7680
5
-
6
- # Install system dependencies
7
- RUN apt-get update && apt-get install -y \
8
- curl \
9
- wget \
10
- git \
11
- sudo \
12
- nano \
13
- vim \
14
- unzip \
15
- zip \
16
- python3 \
17
- python3-pip \
18
- python3-venv \
19
- python3-dev \
20
- build-essential \
21
- chromium \
22
- chromium-driver \
23
- ca-certificates \
24
- gnupg \
25
- && rm -rf /var/lib/apt/lists/*
26
-
27
- # Install Node.js 20
28
- RUN curl -fsSL https://deb.nodesource.com/setup_20.x | bash - && \
29
- apt-get update && \
30
- apt-get install -y nodejs && \
31
- rm -rf /var/lib/apt/lists/*
32
-
33
- # Install code-server
34
- RUN curl -fsSL https://code-server.dev/install.sh | sh
35
-
36
- # Upgrade pip
37
- RUN python3 -m pip install --no-cache-dir --upgrade pip setuptools wheel
38
-
39
- # Install Python packages
40
- RUN pip3 install --no-cache-dir \
41
- selenium \
42
- webdriver-manager \
43
- fake-useragent \
44
- requests \
45
- aiohttp \
46
- beautifulsoup4 \
47
- lxml \
48
- flask \
49
- fastapi \
50
- uvicorn \
51
- python-dotenv \
52
- rich
53
-
54
- # Install global npm packages
55
- RUN npm install -g \
56
- pnpm \
57
- yarn \
58
- typescript \
59
- ts-node \
60
- nodemon \
61
- pm2
62
-
63
- # Create non-root user
64
- RUN useradd -m -s /bin/bash coder && \
65
- echo "coder ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers
66
 
67
  USER coder
68
  WORKDIR /home/coder/project
69
 
70
- # Environment variables for Selenium
71
- ENV CHROME_BIN=/usr/bin/chromium
72
- ENV CHROMEDRIVER=/usr/bin/chromedriver
73
-
74
  EXPOSE 7680
75
 
76
- CMD ["sh", "-c", "code-server --bind-addr 0.0.0.0:${PORT} --auth none /home/coder/project"]
 
1
+ FROM codercom/code-server:latest
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2
 
3
  USER coder
4
  WORKDIR /home/coder/project
5
 
 
 
 
 
6
  EXPOSE 7680
7
 
8
+ CMD ["code-server", "--bind-addr", "0.0.0.0:7680", "--auth", "none", "/home/coder/project"]