Skip to content

Commit

Permalink
Add Paperclip options
Browse files Browse the repository at this point in the history
  • Loading branch information
codycooperross committed Jan 14, 2025
1 parent 95d4811 commit 3fadb46
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 2 deletions.
3 changes: 2 additions & 1 deletion config/environments/development.rb
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@
config.flipper.memoize = false

config.hosts << "lupo_web"


Paperclip.options[:image_magick_path] = "/usr/bin/"
Paperclip.options[:command_path] = "/usr/bin/"
end

Expand Down
1 change: 1 addition & 0 deletions config/environments/production.rb
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@
},
bucket: ENV["AWS_S3_BUCKET"],
}
Paperclip.options[:image_magick_path] = "/usr/bin/"
Paperclip.options[:command_path] = "/usr/bin/"

require "flipper/middleware/memoizer"
Expand Down
1 change: 1 addition & 0 deletions config/environments/stage.rb
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@
},
bucket: ENV["AWS_S3_BUCKET"],
}
Paperclip.options[:image_magick_path] = "/usr/bin/"
Paperclip.options[:command_path] = "/usr/bin/"

require "flipper/middleware/memoizer"
Expand Down
3 changes: 2 additions & 1 deletion config/environments/test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@
# Bullet.counter_cache_enable = false
# end
config.log_level = :ERROR


Paperclip.options[:image_magick_path] = "/usr/bin/"
Paperclip.options[:command_path] = "/usr/bin/"
end
1 change: 1 addition & 0 deletions config/environments/uat.rb
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
},
bucket: ENV["AWS_S3_BUCKET"],
}
Paperclip.options[:image_magick_path] = "/usr/bin/"
Paperclip.options[:command_path] = "/usr/bin/"

require "flipper/middleware/memoizer"
Expand Down
1 change: 1 addition & 0 deletions spec/models/provider_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@
subject { build(:provider) }

it "with logo" do
pp Paperclip.options
subject.logo =
"data:image/png;base64," +
Base64.strict_encode64(file_fixture("bl.png").read)
Expand Down
1 change: 1 addition & 0 deletions spec/requests/providers_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,7 @@

it "creates a provider" do
post "/providers", params, headers
pp Paperclip.options

expect(last_response.status).to eq(200)
expect(json.dig("data", "attributes", "name")).to eq("British Library")
Expand Down

0 comments on commit 3fadb46

Please sign in to comment.