【发布时间】:2016-10-08 08:40:33
【问题描述】:
我的应用程序是托管在 heroku 服务器上的炼油厂CMS。我需要将图像存储在 postgres 数据库存储中。我得到了一颗宝石dragonfly-activerecord,但无法将其保存在数据库中。我试过了:
配置 Dragonfly 本身(通常在 config/initializers/dragonfly.rb 中):
require 'dragonfly-activerecord/store'
Dragonfly.app.configure do
# ... your existing configuration here
datastore Dragonfly::ActiveRecord::Store.new
我们需要将此 gem 集成到refineryCMS 中。如果我们可以将图像存储在cms 的数据库中,这将对像heroku 这样的主机有很大帮助。
【问题讨论】:
标签: postgresql ruby-on-rails-4 heroku refinerycms dragonfly-gem