Niansuh commited on
Commit
a8df8d6
·
verified ·
1 Parent(s): bd1b497

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +9 -8
Dockerfile CHANGED
@@ -8,13 +8,14 @@ ENV PYTHONUNBUFFERED=1 \
8
  # Set the working directory inside the container
9
  WORKDIR /app
10
 
11
- # Install system dependencies (if any)
12
- # Uncomment the following lines if your application requires additional system packages
13
- # RUN apt-get update && apt-get install -y \
14
- # build-essential \
15
- # libssl-dev \
16
- # libffi-dev \
17
- # && rm -rf /var/lib/apt/lists/*
 
18
 
19
  # Copy the requirements file into the container
20
  COPY requirements.txt .
@@ -32,4 +33,4 @@ COPY . .
32
  EXPOSE 8000
33
 
34
  # Define the default command to run the application using Uvicorn
35
- CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000"]
 
8
  # Set the working directory inside the container
9
  WORKDIR /app
10
 
11
+ # Install system dependencies
12
+ RUN apt-get update && apt-get install -y \
13
+ build-essential \
14
+ libssl-dev \
15
+ && rm -rf /var/lib/apt/lists/*
16
+
17
+ # Install mysqlclient dependencies if using mysqlclient instead of pymysql
18
+ # Since we're using pymysql, no additional system dependencies are required
19
 
20
  # Copy the requirements file into the container
21
  COPY requirements.txt .
 
33
  EXPOSE 8000
34
 
35
  # Define the default command to run the application using Uvicorn
36
+ CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000"]