mirror of
https://github.com/YMFE/yapi.git
synced 2025-01-30 13:20:24 +08:00
docs: add mail config
This commit is contained in:
parent
ccdc8af4e5
commit
7ad0134cc3
34
README.md
34
README.md
@ -5,7 +5,7 @@
|
||||
|
||||
YApi 是<strong>高效</strong>、<strong>易用</strong>、<strong>功能强大</strong>的 api 管理平台,旨在为开发、产品、测试人员提供更优雅的接口管理服务。可以帮助开发者轻松创建、发布、维护 API,YApi 还为用户提供了优秀的交互体验,开发人员只需利用平台提供的接口数据写入工具以及简单的点击操作就可以实现接口的管理。
|
||||
|
||||
QQ交流群: 644642474
|
||||
**QQ交流群**: 644642474
|
||||
|
||||
### 特性
|
||||
1. 基于 Json5 和 Mockjs 定义接口返回数据的结构和文档,效率提升多倍
|
||||
@ -19,20 +19,46 @@ QQ交流群: 644642474
|
||||
* nodejs(7.6+)
|
||||
* mongodb(2.6+)
|
||||
#### 安装
|
||||
使用我们提供的 yapi-cli 工具,部署 YApi 平台是非常容易的。执行 yapi-cli server 启动可视化部署程序,输入相应的配置和点击开始部署,就能完成整个网站的部署。部署完成之后,可按照提示信息,执行 node/{网站路径/server/app.js} 启动服务器
|
||||
使用我们提供的 yapi-cli 工具,部署 YApi 平台是非常容易的。执行 yapi-cli server 启动可视化部署程序,输入相应的配置和点击开始部署,就能完成整个网站的部署。部署完成之后,可按照提示信息,执行 node/{网站路径/server/app.js} 启动服务器。在浏览器打开指定url, 点击登录输入您刚才设置的管理员邮箱,默认密码为 ymfe.org 登录系统(默认密码可在个人中心修改)。
|
||||
|
||||
npm install -g yapi-cli --registry https://registry.npm.taobao.org
|
||||
yapi-cli server
|
||||
|
||||
#### 更新
|
||||
cd {项目目录}
|
||||
yapi-cli ls //查看版本号列表
|
||||
yapi-cli update -v v1.1.0
|
||||
|
||||
#### 配置邮箱 (仅支持 SMTP)
|
||||
打开项目目录 config.json 文件,新增 mail 配置, 替换默认的邮箱配置
|
||||
```javascript
|
||||
|
||||
{
|
||||
"port": "*****",
|
||||
"adminAccount": "********",
|
||||
"db": {...},
|
||||
"mail": {
|
||||
"enable": true,
|
||||
"host": "smtp.163.com", //邮箱服务器
|
||||
"port": 465, //端口
|
||||
"from": "***@163.com", //发送人邮箱
|
||||
"auth": {
|
||||
"user": "***@163.com", //邮箱服务器账号
|
||||
"pass": "*****" //邮箱服务器密码
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
### 在线demo
|
||||
<p><a target="_blank" href="http://yapi.demo.qunar.com">yapi.demo.qunar.com</a></p>
|
||||
|
||||
管理员账号
|
||||
* yapi.demo@qunar.com
|
||||
* ymfe.org
|
||||
|
||||
用户名: yapi.demo@qunar.com
|
||||
|
||||
密码: ymfe.org
|
||||
|
||||
### License
|
||||
Apache Licene 2.0
|
||||
|
@ -9,6 +9,7 @@
|
||||
"pass": "test1"
|
||||
},
|
||||
"mail": {
|
||||
"enable": true,
|
||||
"host": "smtp.163.com",
|
||||
"port": 465,
|
||||
"from": "***@163.com",
|
||||
|
Loading…
Reference in New Issue
Block a user