How do I upload images to my heroku app

Viewed 12691

I am following a tutorial on deploying a Rails app to Heroku. It is using a free heroku account with a name like tranquil-mountain-51138.herokuapp.com. The tutorial does not cover adding images. I have a simple test site up and working. Now, I'd like to add a few images to the site, but have no idea how to do this.

On non-heroku, non-rails apps I use FileZilla to ftp files to the server, so I'm very familiar with that. Is there something similar for heroku?

Would someone point me to a tutorial on how to do this?

Much appreciated.

EDITED I would like to upload a photo to appear on my public/index.html page. That's all. I created and deployed a simple job-tracking app, which does not need pictures. Now I am just looking for a "how to" on adding images to an app on heroku - for learning purposes.

Thanks

4 Answers

You can not store in Heroku's filesystem as that use to change after some time but yes you can use s3 provided by aws or there is an app available into Heroku https://elements.heroku.com/addons/cloudinary can help you to store images.

Also if you want to upload the image into the background you can use Redis to do that as there is not fix filesystem for it you can follow the link for same

Related