Gintarė Zokaitytė commited on
Commit
f719912
·
1 Parent(s): a938dc7
Files changed (5) hide show
  1. .python-version +1 -0
  2. Dockerfile +11 -4
  3. pyproject.toml +12 -0
  4. requirements.txt +0 -4
  5. uv.lock +0 -0
.python-version ADDED
@@ -0,0 +1 @@
 
 
1
+ 3.12
Dockerfile CHANGED
@@ -1,17 +1,24 @@
1
- FROM python:3.11-slim
 
2
 
3
  WORKDIR /app
4
 
5
  # Install dependencies
6
- COPY requirements.txt .
7
- RUN pip install --no-cache-dir -r requirements.txt
 
 
8
 
9
  # Copy app files
10
  COPY app.py .
11
  COPY .streamlit .streamlit
12
 
 
 
 
 
13
  # Expose port
14
- EXPOSE 7860
15
 
16
  # Run streamlit
17
  CMD ["streamlit", "run", "app.py", "--server.port=7860", "--server.address=0.0.0.0"]
 
1
+ FROM python:3.12-slim
2
+ COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/
3
 
4
  WORKDIR /app
5
 
6
  # Install dependencies
7
+ RUN --mount=type=cache,target=/root/.cache/uv \
8
+ --mount=type=bind,source=uv.lock,target=uv.lock \
9
+ --mount=type=bind,source=pyproject.toml,target=pyproject.toml \
10
+ uv sync --frozen --no-install-project
11
 
12
  # Copy app files
13
  COPY app.py .
14
  COPY .streamlit .streamlit
15
 
16
+ # Sync the project
17
+ RUN --mount=type=cache,target=/root/.cache/uv \
18
+ uv sync --frozen
19
+
20
  # Expose port
21
+ EXPOSE 8501
22
 
23
  # Run streamlit
24
  CMD ["streamlit", "run", "app.py", "--server.port=7860", "--server.address=0.0.0.0"]
pyproject.toml ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [project]
2
+ name = "annotation-dashboard"
3
+ version = "0.1.0"
4
+ description = "Add your description here"
5
+ readme = "README.md"
6
+ requires-python = ">=3.12"
7
+ dependencies = [
8
+ "pandas>=2.3.3",
9
+ "plotly>=6.5.2",
10
+ "requests>=2.32.5",
11
+ "streamlit>=1.53.1",
12
+ ]
requirements.txt DELETED
@@ -1,4 +0,0 @@
1
- streamlit>=1.28.0
2
- pandas>=2.0.0
3
- plotly>=5.17.0
4
- requests>=2.31.0
 
 
 
 
 
uv.lock ADDED
The diff for this file is too large to render. See raw diff