I've been using the /tmp directory of elastic beanstalk to generate files that I would like to make available for users to download. However, I'm having some trouble linking properly to that folder from a view. Below is what I've tried:
<a href= <%= "/tmp/#{@project.id}/doc.kml" %> download>Download KML</a>
This filepath works in the project model and project controller pages, but not when accessed from the view. From the view page, it resolves as follows, with "no file found":
http://my_app_name.elasticbeanstalk.com/tmp/1/doc.kml
I believe this is pointing to the tmp folder of my app root directory, while I want to go up a level outside the app root for the tmp directory there. Is there a trick to accomplish this?