CrazyMonkey0 commited on
Commit
ad141ba
·
1 Parent(s): 347b2fa

fix(docker): replacing python:3.12-slim with python:3.12-alpine

Browse files
Files changed (1) hide show
  1. Dockerfile +7 -8
Dockerfile CHANGED
@@ -1,18 +1,17 @@
1
- FROM python:3.12-slim
2
  WORKDIR /app
3
 
4
- # Tylko curl i wget - BEZ build-essential i cmake!
5
- RUN apt-get update && apt-get install -y \
6
- wget \
7
- curl \
8
- && rm -rf /var/lib/apt/lists/*
9
 
10
  COPY ./requirements.txt /app/requirements.txt
11
 
12
  RUN pip install --upgrade pip
13
 
14
- # WYMUŚ pre-built wheel - dodaj --prefer-binary
15
- RUN pip install llama-cpp-python --prefer-binary \
16
  --extra-index-url https://abetlen.github.io/llama-cpp-python/whl/cpu
17
 
18
  RUN pip install --no-cache-dir -r requirements.txt
 
1
+ FROM python:3.12-alpine
2
  WORKDIR /app
3
 
4
+ # Minimalne zależności dla Alpine
5
+ RUN apk add --no-cache \
6
+ libstdc++ \
7
+ libgcc
 
8
 
9
  COPY ./requirements.txt /app/requirements.txt
10
 
11
  RUN pip install --upgrade pip
12
 
13
+ # Pre-built musl wheel dla Alpine - ~30 sekund
14
+ RUN pip install llama-cpp-python \
15
  --extra-index-url https://abetlen.github.io/llama-cpp-python/whl/cpu
16
 
17
  RUN pip install --no-cache-dir -r requirements.txt