58bits/cloudfront-signer — pull request #3 by subdigital (2013-04-21 21:12:22+00:00)
Title: Support for providing a signing key as a string instead of a file

In environments like Heroku, it is common to provide secrets via env vars, and not to check them into your source repository.

This change adds a new config option, `key_string`. If this is provided, then `key_pair_id` must also be provided, since it cannot be inferred by any filename.

The original implementation of `key_path=` now delegates to `key_string=` in order to create the underlying RSA key.

Added specs for this configuration as well, and all specs currently pass.