chartManD commited on
Commit
df3eb83
·
1 Parent(s): 268cd30

Creacion de Dockerfile para servidor

Browse files
Files changed (2) hide show
  1. Dockerfile +35 -0
  2. docker-compose.yml +0 -0
Dockerfile ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM ubuntu:24.04
2
+
3
+ ENV DEBIAN_FRONTEND=noninteractive
4
+
5
+ RUN apt-get update && apt-get install -y \
6
+ build-essential \
7
+ libpq-dev \
8
+ python3 python3-dev python3-pip python3-venv \
9
+ gcc pkg-config \
10
+ default-libmysqlclient-dev \
11
+ nodejs npm \
12
+ && rm -rf /var/lib/apt/lists/*
13
+
14
+ WORKDIR /cata_system
15
+
16
+ RUN npm install -g pnpm
17
+
18
+ COPY requirements.txt .
19
+
20
+ RUN python3 -m venv /opt/venv
21
+ ENV PATH="/opt/venv/bin:$PATH"
22
+
23
+ RUN pip install --upgrade pip && \
24
+ pip install wheel && \
25
+ pip install -r requirements.txt
26
+
27
+ COPY . .
28
+
29
+ RUN python3 manage.py tailwind install
30
+ RUN python3 manage.py tailwind build
31
+ RUN python3 manage.py collectstatic --noinput
32
+
33
+ EXPOSE 7860
34
+
35
+ CMD ["python3", "manage.py", "runserver", "0.0.0.0:7860"]
docker-compose.yml ADDED
File without changes