本项目是 DPoS Club 源码基于MIT 协议的开源版本,可以通过https://dpos.club预览最终效果。
DPoS Club https://dpos.club 是一个讨论基于DPoS共识的区块链技术社区。Homeland Integrated with YOYOW基于开源的论坛系统Homeland搭建,并通过YOYOW中间件与YOYOW链上数据(比如账号体系)进行绑定。
现将所有代码开源,欢迎提Issue。
Homeland Integrated with YOYOW在Homeland的基础上,主要添加如下功能:
- 通过YOYOW中间件,添加YOYOW账号绑定
- 通过YOYOW中间件,实现通过YOYOW账号登录
- 添加资产功能,可以查看账户资产的余额以及详细变更情况
- 管理后台添加资产发放功能
- 改进新首页,支持头条文章的分类等
- Ruby >= 2.4.0
- PostgreSQL >= 9.4
- Redis >= 2.8
- Memcached >= 1.4
- Elasticsearch >= 2.0
当前版本基于Homeland v3.1.2修改,部署方式可以参考Homeland的部署方式和配置,https://gethomeland.com。
以Ubuntu 16.04 下的安装为例
sudo apt-get install memcached postgresql libpq-dev postgresql-contrib redis-server imagemagick ghostscriptgem install bundler --conservative
bundle
# 修改配置
for file in config/*.yml.default; do cp $file "${file%.default}"; done
# 数据库环境初始化
RAILS_ENV=production bundle exec rake db:setup
# ES 环境初始化
RAILS_ENV=production bundle exec rake environment elasticsearch:import:model CLASS=Topic FORCE=y
RAILS_ENV=production bundle exec rake environment elasticsearch:import:model CLASS=Page FORCE=y
RAILS_ENV=production bundle exec rake environment elasticsearch:import:model CLASS=User FORCE=y
# Assets 压缩
RAILS_ENV=production bundle exec rails assets:precompile Homeland 的具体配置 详见https://gethomeland.com/docs/
如果开启YOYOW模块,需要部署YOYOW中间件yoyow-middleware,
并在配置 config/config.yml 中 修改 yoyow_middleware_url 的地址即可。
RAILS_ENV=production bundle exec sidekiq -C config/sidekiq.yml -L /var/www/log/sidekiq.log
RAILS_ENV=production bundle exec puma -C config/puma.rbngnix 配置示例可以参考 文件 dposclub.conf.nginx。
Homeland Integrated with YOYOW 基于 MIT 协议开源,