Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

493
Views
OpenURI::HTTPError en ArticlesController#download 403 Prohibido - S3 - Rails

Simplemente estoy tratando de permitir que mi aplicación descargue archivos que están almacenados en s3. Esto parece sencillo, pero sigo recibiendo este error OpenURI::HTTPError in ArticlesController#download 403 Forbidden

Aquí está mi controlador:

 def download article = Article.find_by(id: params[:id]) data = File.read(open("https://s3.us-east-2.amazonaws.com/theranostics-bucket/uploads/DMS-OctoberSocialMedia.pdf")) send_data data, filename: "file.pdf", type: "application/pdf", disposition: 'inline', stream: 'true', buffer_size: '4096' end

Falla en la línea File.read. ¿Qué me estoy perdiendo? Estoy usando Carrierwave para cargar los archivos y funciona bien. Solo cuando trato de descargar tengo problemas.

over 4 years ago · Santiago Trujillo
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!