Trigger82 commited on
Commit
7d4fc93
·
verified ·
1 Parent(s): 38f9011

Create Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +34 -0
Dockerfile ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM node:23-bookworm
2
+
3
+ # Install system dependencies
4
+ RUN apt-get update && apt-get install -y \
5
+ python3 \
6
+ python3-pip \
7
+ git \
8
+ build-essential \
9
+ python-is-python3 \
10
+ && rm -rf /var/lib/apt/lists/*
11
+
12
+ # Install yarn and pm2 globally
13
+ RUN npm install -g yarn pm2
14
+
15
+ # Set environment variables
16
+ ENV PATH="${PATH}:/usr/local/bin"
17
+ ENV PM2_HOME=/tmp/.pm2
18
+ ENV NPM_CONFIG_CACHE=/tmp/npm_cache
19
+ ENV YARN_CACHE_FOLDER=/tmp/yarn_cache
20
+ ENV NODE_ENV=production
21
+ ENV NODE_OPTIONS=--max-old-space-size=512
22
+
23
+ # Create app directory
24
+ WORKDIR /app
25
+
26
+ # Copy requirements and install Python dependencies
27
+ COPY requirements.txt .
28
+ RUN pip install --no-cache-dir -r requirements.txt
29
+
30
+ # Copy the rest of the files
31
+ COPY . .
32
+
33
+ # Start script
34
+ CMD ["python3", "app.py"]