mirror of
https://github.com/LLM-Red-Team/kimi-free-api.git
synced 2024-11-01 20:09:20 +08:00
47 lines
525 B
Markdown
47 lines
525 B
Markdown
|
# KIMI Free 服务
|
|||
|
|
|||
|
## 安装
|
|||
|
|
|||
|
请先安装好Node.js环境并且配置好环境变量,确认node命令可用。
|
|||
|
|
|||
|
安装依赖
|
|||
|
|
|||
|
```shell
|
|||
|
npm i
|
|||
|
```
|
|||
|
|
|||
|
安装PM2进行进程守护
|
|||
|
|
|||
|
```shell
|
|||
|
npm i -g pm2
|
|||
|
```
|
|||
|
|
|||
|
编译构建,看到dist目录就是构建完成
|
|||
|
|
|||
|
```shell
|
|||
|
npm run build
|
|||
|
```
|
|||
|
|
|||
|
启动服务
|
|||
|
|
|||
|
```shell
|
|||
|
pm2 start dist/index.js --name "kimi-free-api"
|
|||
|
```
|
|||
|
|
|||
|
查看服务实时日志
|
|||
|
|
|||
|
```shell
|
|||
|
pm2 logs kimi-free-api
|
|||
|
```
|
|||
|
|
|||
|
重启服务
|
|||
|
|
|||
|
```shell
|
|||
|
pm2 reload kimi-free-api
|
|||
|
```
|
|||
|
|
|||
|
停止服务
|
|||
|
|
|||
|
```shell
|
|||
|
pm2 stop kimi-free-api
|
|||
|
```
|