Gleb Gleb commited on
Commit
cddda61
·
1 Parent(s): 66ecc97
Files changed (1) hide show
  1. Dockerfile +6 -6
Dockerfile CHANGED
@@ -2,30 +2,30 @@
2
  FROM python:3.11-slim
3
 
4
  # Set environment variables for Java and cache directory
5
- ENV JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64
6
  ENV XDG_CACHE_HOME=/tmp/.cache
7
  ENV PATH="${JAVA_HOME}/bin:${PATH}"
8
 
9
  # Set working directory
10
  WORKDIR /app
11
 
12
- # Install system dependencies: Java and build tools
13
  RUN apt-get update && apt-get install -y --no-install-recommends \
14
- openjdk-11-jdk \
15
  build-essential \
16
  curl \
17
  && rm -rf /var/lib/apt/lists/*
18
 
19
- # Copy your app code (app.py etc.)
20
  COPY . .
21
 
22
  # Upgrade pip
23
  RUN pip install --upgrade pip
24
 
25
- # Install the impresso-pipelines package from PyPI with extras
26
  RUN pip install "impresso_pipelines[solrnormalization]==0.4.6.4"
27
 
28
- # Install Gradio separately if it's not in your package's dependencies
29
  RUN pip install gradio
30
 
31
  # Expose Gradio default port
 
2
  FROM python:3.11-slim
3
 
4
  # Set environment variables for Java and cache directory
5
+ ENV JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64
6
  ENV XDG_CACHE_HOME=/tmp/.cache
7
  ENV PATH="${JAVA_HOME}/bin:${PATH}"
8
 
9
  # Set working directory
10
  WORKDIR /app
11
 
12
+ # Install Java 17 and build tools
13
  RUN apt-get update && apt-get install -y --no-install-recommends \
14
+ openjdk-17-jdk \
15
  build-essential \
16
  curl \
17
  && rm -rf /var/lib/apt/lists/*
18
 
19
+ # Copy app code (app.py etc.)
20
  COPY . .
21
 
22
  # Upgrade pip
23
  RUN pip install --upgrade pip
24
 
25
+ # Install your PyPI package with solrnormalization extras
26
  RUN pip install "impresso_pipelines[solrnormalization]==0.4.6.4"
27
 
28
+ # Install gradio if not already pulled in
29
  RUN pip install gradio
30
 
31
  # Expose Gradio default port