Update Dockerfile
Browse files- Dockerfile +11 -27
Dockerfile
CHANGED
|
@@ -1,32 +1,23 @@
|
|
| 1 |
# Base image
|
| 2 |
FROM python:3.10-slim
|
| 3 |
|
| 4 |
-
# Set environment variables
|
| 5 |
-
ENV PYTHONDONTWRITEBYTECODE=1
|
| 6 |
-
ENV PYTHONUNBUFFERED=1
|
| 7 |
-
ENV PORT=7860
|
| 8 |
-
|
| 9 |
# Set working directory
|
| 10 |
WORKDIR /app
|
| 11 |
|
| 12 |
# Install system dependencies
|
| 13 |
RUN apt-get update && apt-get install -y \
|
| 14 |
-
git \
|
| 15 |
-
curl \
|
| 16 |
-
gnupg \
|
| 17 |
-
unzip \
|
| 18 |
-
nodejs \
|
| 19 |
-
npm \
|
| 20 |
-
supervisor \
|
| 21 |
&& rm -rf /var/lib/apt/lists/*
|
| 22 |
|
| 23 |
-
# Install bun
|
| 24 |
-
RUN
|
|
|
|
|
|
|
| 25 |
|
| 26 |
# Install uv (Python package manager)
|
| 27 |
RUN curl -Ls https://astral.sh/uv/install.sh | bash
|
| 28 |
|
| 29 |
-
# Clone Devika
|
| 30 |
RUN git clone https://github.com/stitionai/devika.git ./
|
| 31 |
|
| 32 |
# Set up virtual environment
|
|
@@ -39,18 +30,11 @@ RUN uv pip install -r requirements.txt
|
|
| 39 |
# Install Playwright dependencies and browsers
|
| 40 |
RUN .venv/bin/playwright install --with-deps
|
| 41 |
|
| 42 |
-
#
|
| 43 |
-
|
| 44 |
-
RUN bun install
|
| 45 |
-
|
| 46 |
-
# Return to root directory
|
| 47 |
-
WORKDIR /app
|
| 48 |
-
|
| 49 |
-
# Copy supervisord configuration
|
| 50 |
-
COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf
|
| 51 |
|
| 52 |
-
# Expose
|
| 53 |
EXPOSE 7860
|
| 54 |
|
| 55 |
-
# Start
|
| 56 |
-
CMD ["
|
|
|
|
| 1 |
# Base image
|
| 2 |
FROM python:3.10-slim
|
| 3 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 4 |
# Set working directory
|
| 5 |
WORKDIR /app
|
| 6 |
|
| 7 |
# Install system dependencies
|
| 8 |
RUN apt-get update && apt-get install -y \
|
| 9 |
+
git curl gnupg unzip \
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 10 |
&& rm -rf /var/lib/apt/lists/*
|
| 11 |
|
| 12 |
+
# Install Node.js 18 and bun
|
| 13 |
+
RUN curl -fsSL https://deb.nodesource.com/setup_18.x | bash - && \
|
| 14 |
+
apt-get install -y nodejs && \
|
| 15 |
+
npm install -g bun
|
| 16 |
|
| 17 |
# Install uv (Python package manager)
|
| 18 |
RUN curl -Ls https://astral.sh/uv/install.sh | bash
|
| 19 |
|
| 20 |
+
# Clone Devika repo
|
| 21 |
RUN git clone https://github.com/stitionai/devika.git ./
|
| 22 |
|
| 23 |
# Set up virtual environment
|
|
|
|
| 30 |
# Install Playwright dependencies and browsers
|
| 31 |
RUN .venv/bin/playwright install --with-deps
|
| 32 |
|
| 33 |
+
# Set environment variable for port if needed
|
| 34 |
+
ENV PORT=7860
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 35 |
|
| 36 |
+
# Expose backend port (you'll need to modify the code to bind to 7860 if it defaults to something else)
|
| 37 |
EXPOSE 7860
|
| 38 |
|
| 39 |
+
# Start backend (adjust path if needed)
|
| 40 |
+
CMD ["python", "devika.py"]
|