Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/baohaoyu/oos_blog_server

koa2搭建的hexo博客,配有上传到阿里云OOS接口
https://github.com/baohaoyu/oos_blog_server

aliyun aliyun-oss hexo koa2

Last synced: about 1 month ago
JSON representation

koa2搭建的hexo博客,配有上传到阿里云OOS接口

Awesome Lists containing this project

README

        

# koa2博客服务

## 安装

按顺序执行如下命令

```bash
git clone https://github.com/BaoHaoYu/oos_blog_server.git
cd oos_blog_server
yarn
```

## 配置config.ts

```ts
export default {
// 端口
port: '9000',
// blog静态目录
blogPublic: '/opt/www/hexo-blog/public',
// 域名
region: '',
// 阿里云accessKeyId
accessKeyId: '',
// 阿里云accessKeySecret
accessKeySecret: '',
}
```

region
![](http://bhyblog.oss-cn-shenzhen.aliyuncs.com/hexo/chrome_qtiqWEFZDi.png)

accessKeyId和accessKeySecret
![](http://bhyblog.oss-cn-shenzhen.aliyuncs.com/hexo/chrome_vOVtY39Be9.png)

blogPublic为`hexo generate`生成静态文件的位置

## 通过pm2运行项目

```bash
pm2 start pm2.json
```