Download Dockerfile from timindev/mytestweb: direct link, hf CLI and curl.
- Browser
- Download file 457 Bytes
-
https://huggingface.co/spaces/timindev/mytestweb/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/timindev/mytestweb/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/timindev/mytestweb/resolve/main/Dockerfile
457 Bytes
| # 使用轻量级的 Node.js 镜像 | |
| FROM node:18-slim | |
| # 安装 git 以克隆代码 | |
| RUN apt-get update && apt-get install -y git && rm -rf /var/lib/apt/lists/* | |
| # 克隆 Ultraviolet 的官方精简部署版 | |
| RUN git clone https://github.com/titaniumnetwork-dev/Ultraviolet-App.git /app | |
| WORKDIR /app | |
| # 安装依赖 | |
| RUN npm install | |
| # 设置 Hugging Face 必须的 7860 端口 | |
| ENV PORT=7860 | |
| EXPOSE 7860 | |
| # 启动程序 | |
| CMD ["npm", "start"] |