Ruby client for Camo - the SSL image proxy
Ruby
Latest commit 8b47e41 Oct 18, 2016 @ankane Updated readme
Permalink
Failed to load latest commit information.
lib Version bump to 0.1.0 Oct 17, 2016
test adding tests Jun 20, 2016
.gitignore First commit Nov 26, 2013
Gemfile First commit Nov 26, 2013
LICENSE.txt First commit Nov 26, 2013
README.md Updated readme Oct 18, 2016
Rakefile adding tests Jun 20, 2016
camo.gemspec adding tests Jun 20, 2016

README.md

Camo

Ruby client for Camo - the SSL image proxy 🔒

Get Started

Note: If you have not set up the Camo server, start with Deploying the Server.

Add this line to your application’s Gemfile:

gem "camo"

Add your Camo host and key to your environment or create an initializer config/initializers/camo.rb.

ENV["CAMO_HOST"] = "https://camo.herokuapp.com"
ENV["CAMO_KEY"] = "rzsJbU5YxDfdP3FXHjshtgEN"

You can now use the camo method in your views and controllers.

<%= image_tag camo("http://placekitten.com/g/200/300") %>

It’s that easy!

Deploying the Server

Clone the camo repository.

git clone https://github.com/atmos/camo.git
cd camo

Create a new project on Heroku.

heroku create myapp-camo
git push heroku master

Choose a random secret key and add it to your app.

heroku config:set CAMO_KEY=rzsJbU5YxDfdP3FXHjshtgEN

Open your app to make sure it’s working. You should see the text “hwhat”.

heroku open

Credit

Thanks to Corey Donohoe for creating Camo and providing most of the Ruby code for this gem.

Contributing

Everyone is encouraged to help improve this project. Here are a few ways you can help: