Spaces:
Sleeping
Sleeping
| # read the doc: https://huggingface.co/docs/hub/spaces-sdks-docker | |
| # you will also find guides on how best to write your Dockerfile | |
| FROM python:3.11 | |
| RUN pip install --no-cache-dir --upgrade pip | |
| RUN mkdir /dep | |
| WORKDIR /dep | |
| RUN git clone https://github.com/jaigouk/claude-proxy-api.git | |
| WORKDIR /dep/claude-proxy-api | |
| RUN useradd -m -u 1000 user | |
| USER user | |
| ENV PATH="/home/user/.local/bin:$PATH" | |
| RUN pip install -r requirements.txt | |
| COPY --chown=user proxy.env ./.env | |
| WORKDIR /app | |
| COPY --chown=user ./requirements.txt requirements.txt | |
| RUN pip install --no-cache-dir --upgrade -r requirements.txt | |
| RUN mkdir -p ./ragtest/input | |
| # RUN curl https://secure.ssa.gov/apps10/poms.nsf/lnx/0500502100 > ./ragtest/input/book.txt | |
| RUN curl https://huggingface.co/spaces/npc0/POM-QA/resolve/main/knowledge_extraction.csv > ./ragtest/input/book.txt | |
| COPY --chown=user ./settings.yaml /app | |
| COPY --chown=user ./app.py /app | |
| COPY --chown=user ./run.sh run.sh | |
| RUN chmod +x run.sh | |
| ENTRYPOINT ["/app/run.sh"] |