前端请移步到Flat-Blog
基于Express,采用TypeORM进行数据库管理
Demo: https://blog.mc-myth.cn
npm install
npm run start
在src/config/blog.config.js
中配置jwt/session/cross相关信息
用于存储用户头像/头图/文章文件上传到腾讯云对象储存
src/config/env.ts
export const env = {
cos: {
secretId: 'Your secretId',
secretKey: 'Your secretKey',
Bucket: 'Your Bucket',
Region: 'Your Region',
remoteBasePath: 'static/',
localBasePath: 'static/',
assetsDomain: 'Your COS Custom Domain'
},
email: {
user: 'Your Email',
pass: 'Your Password'
},
database: {
host: "Your Mysql Host",
port: 3306,
username: "root",
password: "Your Mysql Password",
database: "Your Mysql Database",
}
}