Name: fog-akamai
Owner: fog
Description: Module for the 'fog' gem to support Akamai http://www.akamai.com/
Created: 2015-11-03 13:37:09.0
Updated: 2016-08-05 02:46:55.0
Pushed: 2016-02-10 15:27:32.0
Size: 791
Language: Ruby
GitHub Committers
User | Most Recent Commit | # Commits |
---|
Other Committers
User | Most Recent Commit | # Commits |
---|
Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file lib/fog/storage
. To experiment with that code, run bin/console
for an interactive prompt.
All the functionality of the net storage api is implemented except the really dangerous bit, quick-delete.
Add this line to your application's Gemfile:
'fog-akamai'
And then execute:
$ bundle
Or install it yourself as:
$ gem install fog-akamai
Before you can use fog-akamai, you must require it in your application:
ire 'fog/akamai'
Since it's a bad practice to have your credentials in source code, you should load them from default fog configuration file: `~/.fog
`. This file could look like this:
ult:
amai_host: <YOUR_AKAMAIHOST>
amai_key_name: <YOUR_KEY_NAME>
amai_key: <YOU_KEY>
amai_cp_code: <YOU_CP_CODE>
You can get more detail about how to obtain this credential form this doc
storage = Fog::Compute.new :provider => 'akamai'
ctory = net_storage.directories.get('/path')
ctory.files.stat('file.ext')
ctory.files.create(directory: directory, body: file_body, key: file_name)
After checking out the repo, run bin/setup
to install dependencies. Then, run rake test
to run the tests. You can also run bin/console
for an interactive prompt that will allow you to experiment.
To install this gem onto your local machine, run bundle exec rake install
. To release a new version, update the version number in version.rb
, and then run bundle exec rake release
, which will create a git tag for the version, push git commits and tags, and push the .gem
file to rubygems.org.
Bug reports and pull requests are welcome on GitHub at https://github.com/alexandru-calinoiu/fog-akamai.