Advertisement
Guest User

Untitled

a guest
Feb 12th, 2014
616
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.11 KB | None | 0 0
  1. Missing Credentials. Unable to find AWS credentials.
  2. You can configure your AWS credentials a few different ways:
  3. * Call AWS.config with :access_key_id and :secret_access_key
  4. * Export AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY to ENV *
  5.  
  6. Gmaps::Application.configure do
  7. # Settings specified here will take precedence over those in config/application.rb
  8.  
  9. # In the development environment your application's code is reloaded on
  10. # every request. This slows down response time but is perfect for development
  11. # since you don't have to restart the web server when you make code changes.
  12. config.cache_classes = false
  13.  
  14. # Log error messages when you accidentally call methods on nil.
  15. config.whiny_nils = true
  16.  
  17. # Show full error reports and disable caching
  18. config.consider_all_requests_local = true
  19. config.action_controller.perform_caching = false
  20.  
  21. # Don't care if the mailer can't send
  22. config.action_mailer.raise_delivery_errors = false
  23.  
  24. # Print deprecation notices to the Rails logger
  25. config.active_support.deprecation = :log
  26.  
  27. # Only use best-standards-support built into browsers
  28. config.action_dispatch.best_standards_support = :builtin
  29.  
  30. # Raise exception on mass assignment protection for Active Record models
  31. config.active_record.mass_assignment_sanitizer = :strict
  32.  
  33. # Log the query plan for queries taking more than this (works
  34. # with SQLite, MySQL, and PostgreSQL)
  35. config.active_record.auto_explain_threshold_in_seconds = 0.5
  36.  
  37. # Do not compress assets
  38. config.assets.compress = false
  39.  
  40. # Expands the lines which load the assets
  41. config.assets.debug = true
  42.  
  43. # Amazon S3 settings for Paperclip uploads
  44. Paperclip::Attachment.default_options.merge!({
  45. storage: :s3 ,
  46. s3_credentials: {
  47. access_key_id: ENV['key_id'],
  48. secret_access_key: ENV['key'],
  49. bucket: "#{ENV['bucket']}-#{Rails.env}"
  50. },
  51. url: ":s3_domain_url",
  52. path: "/:class/:attachment/:id_partition/:style/:filename"
  53. })
  54. end
  55.  
  56. class Location < ActiveRecord::Base
  57. geocoded_by :address
  58. after_validation :geocode
  59.  
  60. has_attached_file :picture,
  61. :styles => { :medium => "300x300>", :thumb => "100x100>" }
  62. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement