项目是基于Rails
的一款开源的个人单博客系统。
在线演示 https://zoker.io/
功能
- 文章发布(MD编辑器采用码云开源的 TMD )
- 标签管理(支持多标签管理)
- 分类管理(支持多分类管理)
- 评论管理(评论验证码,审核机制)
- 页面管理(单页面管理)
- 搜索(使用Solr进行索引)
- 后台管理
功能截图
首页
文章界面
搜索功能
发布博客
博客设置
使用
项目基于 Ruby 2.3.1
及以上
- git clone https://gitee.com/kesin/Blogine
- bundle install
- cp database.yml.example database.yml #修改数据库配置
- cp blogine.yml.example blogine.yml #修改博客配置
- cp puma.rb.example puma.rb
- cd Blogine
- bundle exec rake db:migrate
- cp development.rb.example development.rb
- bundle exec puma
访问 http://127.0.0.1:3003
搜索配置(可选)
- 如果不需要搜索功能,可以将
blogine.yml
中的enable_search: false
设置为false
- 如果需要搜索功能,可以设置为
true
配置Solr
- Java: JDK 1.7.X 以上
- 初始化:
rails generate sunspot_rails:install
- 启动:
bundle exec rake sunspot:solr:start
- 如果已经有数据,需要执行重新构建索引:
bundle exec rake sunspot:reindex
生产环境下需要更改如下配置:
cp blogine/solr/default blogine/solr/production
- 并修改
blogine/solr/production/core.properties
的name
为production
贡献代码
- Fork 项目
- 创建本地分支 (
git checkout -b my-new-feature
) - 提交更改 (
git commit -am 'Add some feature'
) - 推送到分支 (
git push origin my-new-feature
) - 创建一个 Pull Request