Spaces:
Paused
Paused
Download Dockerfile0 from onlyrickroll/nginx: direct link, hf CLI and curl.
- Browser
- Download file 829 Bytes
-
https://huggingface.co/spaces/onlyrickroll/nginx/resolve/main/Dockerfile0
- Command line
-
hf download hf://spaces/onlyrickroll/nginx/Dockerfile0
-
curl -L -o Dockerfile0 https://huggingface.co/spaces/onlyrickroll/nginx/resolve/main/Dockerfile0
829 Bytes
| FROM nginx:trixie | |
| # 安装基础依赖 | |
| RUN apt-get update && apt-get install -y \ | |
| build-essential \ | |
| curl \ | |
| git \ | |
| sudo \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # 创建 linuxbrew 用户 | |
| RUN useradd -m -s /bin/bash linuxbrew && \ | |
| echo 'linuxbrew ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers | |
| USER linuxbrew | |
| WORKDIR /home/linuxbrew | |
| # 安装 Homebrew | |
| RUN /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" | |
| # 设置环境变量 | |
| ENV PATH="/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin:${PATH}" | |
| # 测试安装 | |
| RUN brew --version | |
| RUN brew install llama.cpp | |
| COPY nginx.conf /etc/nginx/nginx.conf | |
| WORKDIR /app | |
| RUN chmod 777 /app | |
| USER root | |
| CMD llama-server -hf unsloth/LFM2-8B-A1B-GGUF:Q4_K_M -c 4096 --port "8080" --no-mmap & \ | |
| nginx -g "daemon off;" |