Create a gist now

Instantly share code, notes, and snippets.

Embed
What would you like to do?
config.paperclip_defaults = {
:storage => :s3,
:s3_credentials => {
:bucket => 'BUCKET',
:access_key_id => 'S3_KEY',
:secret_access_key => 'S3_SECRET'
}
}
Paperclip::Attachment.default_options[:s3_protocol] = "https"
Spree::Image.attachment_definitions[:attachment][:styles] = ActiveSupport::JSON.decode('{"mini":"48x48\u003E","small":"100x100\u003E","product":"240x240\u003E","large":"600x600\u003E"}').symbolize_keys!
Spree::Image.attachment_definitions[:attachment][:path] = " /#{Rails.env}/:id/:style/:basename.:extension"
Spree::Image.attachment_definitions[:attachment][:url] = '/spree/products/:id/:style/:basename.:extension'
Spree::Image.attachment_definitions[:attachment][:default_url] = ''
Spree::Image.attachment_definitions[:attachment][:default_style] = 'product'
@subos2008

This comment has been minimized.

Show comment
Hide comment
@subos2008

subos2008 Aug 23, 2014

Why the JSON.decode line?

Why the JSON.decode line?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment