skip to Main Content

As a programming beginner, I deployed a rails app for the first time on Heroku. I got a 500 error and I can’t find the source. If you could help me to find it in the log, that would be great. Please let me know what additional info I need to share to debug.

It’s not long, much to check
Link to log detail: https://pastebin.com/xPAkGWA8

source 'https://rubygems.org'
ruby '2.6.3'

gem 'bootsnap', require: false
gem 'devise'
gem 'jbuilder', '~> 2.0'
gem 'pg', '~> 0.21'
gem 'puma'
gem 'rails', '5.2.3'
gem 'redis'

gem 'autoprefixer-rails'
gem 'font-awesome-sass', '~> 5.6.1'
gem 'sassc-rails'
gem 'simple_form'
gem 'uglifier'
gem 'webpacker'
gem 'pundit'
gem 'dotenv-rails', groups: [:development, :test]
gem 'cloudinary', '~> 1.9.1'
gem 'carrierwave', '~> 1.2'
gem 'geocoder'

group :development do
  gem 'web-console', '>= 3.3.0'
end

group :development, :test do
  gem 'pry-byebug'
  gem 'pry-rails'
  gem 'listen', '~> 3.0.5'
  gem 'spring'
  gem 'spring-watcher-listen', '~> 2.0.0'
  gem 'dotenv-rails'
end

3

Answers


  1. This is the error: ActionView::Template::Error (Must supply cloud_name in tag or in configuration)

    It seems you didn’t configure your CLOUDINARY_URL, as explained here: https://cloudinary.com/documentation/rails_integration#configuration

    How to do it in Heroku: https://devcenter.heroku.com/articles/config-vars

    Login or Signup to reply.
  2. 2019-12-15T07:14:05.514823+00:00 app[web.1]: F, [2019-12-15T07:14:05.514783 #4] FATAL -- : [9d7c7bac-ab26-41b3-8369-75e7d903bbe9] ActionView::Template::Error (Must supply cloud_name in tag or in configuration):
    2019-12-15T07:14:05.514973+00:00 app[web.1]: F, [2019-12-15T07:14:05.514929 #4] FATAL -- : [9d7c7bac-ab26-41b3-8369-75e7d903bbe9]     81:
    2019-12-15T07:14:05.514974+00:00 app[web.1]: [9d7c7bac-ab26-41b3-8369-75e7d903bbe9]     82:       <!--image-->
    2019-12-15T07:14:05.514976+00:00 app[web.1]: [9d7c7bac-ab26-41b3-8369-75e7d903bbe9]     83:
    2019-12-15T07:14:05.514977+00:00 app[web.1]: [9d7c7bac-ab26-41b3-8369-75e7d903bbe9]     84:       <%= link_to cl_image_tag(campaign.campaign_picture, class:"card-campaign-img", width: 278, height: 180, :crop=>"fill"), campaign_path(campaign) %>
    2019-12-15T07:14:05.514978+00:00 app[web.1]: [9d7c7bac-ab26-41b3-8369-75e7d903bbe9]     85:
    2019-12-15T07:14:05.514979+00:00 app[web.1]: [9d7c7bac-ab26-41b3-8369-75e7d903bbe9]     86:       <!--infos-->
    2019-12-15T07:14:05.514980+00:00 app[web.1]: [9d7c7bac-ab26-41b3-8369-75e7d903bbe9]     87:       <div class="card-campaign-infos">
    

    This is the extract, you should look for the “FATAL” identifier.

    Login or Signup to reply.
  3. I think you forget to configure the Heroku app in your rails app.
    You can config it using “Heroku config”.
    OR can follow the link provided by @beauraF.(https://devcenter.heroku.com/articles/config-vars).

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search