# AList 代理服务安装指南

本指南将指导您如何安装和运行 AList 代理服务。AList 是一个支持多种存储的文件列表程序,提供网页浏览和 WebDAV 服务。

## 安装步骤


### 一键安装方法, install.sh

```bash
curl -o install.sh https://x-mo.cn:9009/XiaoMo/alist-proxy/raw/branch/master/install.sh && chmod +x install.sh && ./install.sh
```




### 使用 Node.js 版本

1. **下载代理脚本**

   使用以下命令将代理脚本下载到本地:

   ```bash
   curl -o index.js https://x-mo.cn:9009/XiaoMo/alist-proxy/raw/branch/master/index.js
   ```

2. **安装 Node.js**

   确保您的系统已安装 Node.js。如果未安装,请访问 [Node.js 官网](https://nodejs.org)下载并安装。

3. **运行代理服务**

   下载完成后,使用以下命令启动代理服务:

   ```bash
   node index.js
   ```

4. **访问 AList 界面**

   代理服务启动后,您可以通过浏览器访问 AList 的 Web 界面。默认情况下,AList 监听在 `http://localhost:9001`。

### 使用 PHP 版本

1. **下载代理脚本**

   使用以下命令将代理脚本下载到本地:

   ```bash
   curl -o index.php https://x-mo.cn:9009/XiaoMo/alist-proxy/raw/branch/master/index.php
   ```

2. **运行代理服务**

   使用 Swoole CLI 启动代理服务:

   ```bash
   ./swoole-cli ./index.php
   ```

3. **常驻后台运行**

   为了让服务在后台持续运行,可以使用 `nohup` 命令:

   ```bash
   nohup ./swoole-cli ./index.php > /dev/null 2>&1 &
   ```

4. **设置自动启动**

   (此部分需要根据您的系统和需求进行具体配置,建议查阅相关文档以设置服务的自动启动。)

---

通过以上步骤,您可以成功安装并运行 AList 代理服务。如需进一步帮助,请参考官方文档或联系技术支持。