Coder Social home page Coder Social logo

johnshi521 / milog Goto Github PK

View Code? Open in Web Editor NEW

This project forked from jinhucheung/milog

0.0 1.0 0.0 19.63 MB

Milog 是一基于 Ruby on Rails 的个人博客网站

Home Page: https://github.com/jinhucheung/milog

Ruby 51.22% JavaScript 4.95% CSS 8.89% HTML 28.69% CoffeeScript 6.25%

milog's Introduction

Milog

一基于 Ruby on Rails 的个人博客网站 https://milog-demo.herokuapp.com/

游客账号: Email [email protected] | Password 123456

静态页面: https://github.com/jinhucheung/milog/tree/static_pages

特点

  • 支持 Bootstrap, 实现响应式设计

  • 使用 Markdown 作为编辑文本格式, 主要由 Markdown-it 在客户端进行解析渲染, motion-markdown-it 负责后端解析

  • Markdown 支持 Emoji

  • 实现 Markdown 工具栏

  • 使用 bcrypt 加密用户重要资料

  • 可暂存用户编辑中的文本

  • Elasticsearch 作为全文搜索引擎, 可根据关键字搜索文章

  • 支持上传图片, 使用七牛存储

更新

2016/12/20

  • 增加社区模块

  • 修改用户主页, 增加用户关注功能

  • 增加消息通知系统

2017/1/30

2017/3/14

  • 实现 Milog Android 客户端 Milog-Android

  • 修复文章中图片尺寸过大, 溢出页面

2017/5/7

  • 将原先的 afeld.github.io/emoji-css 文件导入本地

  • 修复客户端用户未登录访问消息通知 404

2017/5/15

  • 后台添加用户后发送密码激活邮件至用户邮箱

  • 修复测试用例

Thanks

部署

环境

Ubuntu 14.04 / Git / Ruby 2.3.1 / Rails 5.0.0 / MariaDB 5.5.52

下载

git clone [email protected]:Hikumho/milog.git

数据库

安装 MariaDB

sudo apt-get install software-properties-common
sudo apt-key adv --recv-keys --keyserver hkp://keyserver.ubuntu.com:80 0xcbcb082a1bb943db
sudo add-apt-repository 'deb http://sfo1.mirrors.digitalocean.com/mariadb/repo/10.0/ubuntu trusty main'

sudo apt-get update
sudo apt-get install mariadb-server

项目配置

  1. 更新配置文件
cp config/local_env.yml.example config/local_env.yml
cp config/email.yml.example config/email.yml

修改 config/local_env.yml 中的 MYSQL 信息

  1. 安装 Gem
bundle install

其他问题可见 #FQA

  1. 迁移数据
rails db:create

rails db:migrate

rails db:seed

至此, 项目可在开发环境中运行

以下进行生产环境的部署

  1. 生成 App 密钥
require 'securerandom'

SecureRandom.hex(64)

并将密钥写入 config/secrets.ymlproduction 节点

  1. 部署七牛云

修改 config/local_env.yml 中的 QINIU 信息

具体配置请看 carrierwave-qiniu

  1. 部署邮件

修改 config/email.yml

FQA

  1. Imagemagick

本地可能由于没有安装 Imagemagick 导致 bundle install 出错

安装 Imagemagick: sudo apt-get install imagemagick

  1. Elasticsearch

安装 Elasticsearch: 教程

配置 Elasticsearch: bundle exec rake environment elasticsearch:import:model CLASS='Article' SCOPE='posted'

milog's People

Contributors

jinhucheung avatar dependabot[bot] avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.