sashdev commited on
Commit
46cf5ec
·
verified ·
1 Parent(s): 3b03846

Create Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +22 -0
Dockerfile ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Base image with Python
2
+ FROM python:3.10-slim
3
+
4
+ # Install Java (required for language_tool_python)
5
+ RUN apt-get update && apt-get install -y openjdk-11-jdk && rm -rf /var/lib/apt/lists/*
6
+
7
+ # Set JAVA_HOME environment variable
8
+ ENV JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64/
9
+ ENV PATH=$JAVA_HOME/bin:$PATH
10
+
11
+ # Copy the application code to the container
12
+ COPY . /app
13
+ WORKDIR /app
14
+
15
+ # Install Python dependencies
16
+ RUN pip install -r requirements.txt
17
+
18
+ # Expose port 7860 for the Gradio app
19
+ EXPOSE 7860
20
+
21
+ # Run the application
22
+ CMD ["python", "app.py"]