Strore pdf in amazon s3 using cron

Skip to first unread message

Saravanan P

Jan 5, 2013, 5:43:57 AM1/5/13
Hello Everyone,

I have one model called Message. 
User can send messages along with 2 more images.
I need to take a pdf of each message and store it in amazon s3 for daily basses.
I need to show that .pdf (one message) file for admin to download that pdf.

I am using wicked_pdf gem to generate pdf and whenever gem for cron task.

I can generate pdf file in browser by "generate_pdf" action.
I dont know how to get pdf and store that amazon using cron.

Please help!

Dheeraj Kumar

Jan 5, 2013, 5:50:51 AM1/5/13
Next time, please read the documentation before asking a question.

Save it to a file like shown above ^^ 

Then use the official aws-s3 gem to upload the file. 

Write a class or a rake task which does the above, then use whenever to schedule it every day.

Dheeraj Kumar

You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to
To unsubscribe from this group, send email to
To view this discussion on the web visit
For more options, visit

Saravanan P

Jan 5, 2013, 9:38:01 AM1/5/13
Hi Dheeraj

Actually i already saw that.. but i didn't knew how to use.

But now i got it by trying trying and facing error and correct myself.
Now i coded rake task to automatically upload each messages as pdf into amazon s3. :)

Thanks for the reply, happy weekend.
Regards by
Reply all
Reply to author
0 new messages