Fabio76 commited on
Commit
6dfd5ec
·
verified ·
1 Parent(s): 778b9ea

Create Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +32 -0
Dockerfile ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Use the official Python image
2
+ FROM python:3.10-slim
3
+
4
+ # Set the working directory in the container
5
+ WORKDIR /app
6
+
7
+ # Install system dependencies
8
+ RUN apt-get update && apt-get install -y \
9
+ build-essential \
10
+ libpq-dev \
11
+ curl \
12
+ docker.io \
13
+ && rm -rf /var/lib/apt/lists/*
14
+
15
+ # Install Docker Compose
16
+ RUN curl -L "https://github.com/docker/compose/releases/download/1.29.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose \
17
+ && chmod +x /usr/local/bin/docker-compose
18
+
19
+ # Copy the current directory contents into the container at /app
20
+ COPY . /app
21
+
22
+ # Install Python dependencies
23
+ RUN pip install --no-cache-dir -r requirements.txt
24
+
25
+ # Expose port 80 to the outside world
26
+ EXPOSE 80
27
+
28
+ # Define environment variables
29
+ ENV NAME Dify
30
+
31
+ # Run the application
32
+ CMD ["docker-compose", "up"]