dimanche 28 juin 2015

Load ruby object from amazon s3 in rails

I want to be able to load .rb object from amazon s3. Now in my project I store my reports in the app/reports directory. They are object extended from Prawn::Document Class (pdf_report.rb):

class PdfReport < Prawn::Document
  def initialize(default_prawn_options={})
    super(default_prawn_options)
  end
  def header(title=nil)
    if title
      text title, size: 14, style: :bold_italic, align: :center
    end
  end
  def footer
  end
end

My objective is to load this classes from an amazon s3 bucket. How can I do this? Thank you.




Aucun commentaire:

Enregistrer un commentaire