-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
33 lines (23 loc) · 829 Bytes
/
Copy pathDockerfile
File metadata and controls
33 lines (23 loc) · 829 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
FROM node:20-slim
# Install Python and required system packages
RUN apt-get update && apt-get install -y --no-install-recommends \
python3 \
python3-pip \
python3-dev \
ca-certificates \
&& rm -rf /var/lib/apt/lists/* \
&& python3 --version \
&& pip3 --version
WORKDIR /app
COPY package*.json ./
RUN rm -f package-lock.json && npm install --legacy-peer-deps
COPY requirements.txt ./
RUN pip3 install -r requirements.txt --break-system-packages \
&& python3 -c "import pandas; import numpy; import boto3; import pyarrow; print('Python packages verified')"
COPY . .
# Create temp directory for deployments
RUN mkdir -p .tmp/deployments && chmod 777 .tmp/deployments
RUN npm run build
EXPOSE 3000
# Clear tmp directory on startup and start the app
CMD rm -rf .tmp/deployments/* && npm start