Fog::Dnsimple
API Version
This library currently uses the DNSimple API v1
and it is fully compatible with the legacy implementation bundled with the fog
gem.
In other words, this is a drop-in replacement. Please note that the dnsimple
provider
will eventually be removed from the fog
gem in favor of this fog-specific module.
Installation
Add this line to your application's Gemfile:
gem 'fog-dnsimple'
And then execute:
$ bundle
Or install it yourself as:
$ gem install fog-dnsimple
Usage
Initialize a Fog::DNS
object using the DNSimple provider.
dns = Fog::DNS.new({
provider: "DNSimple",
dnsimple_token: "YOUR_API_TOKEN",
dnsimple_account: "YOUR_ACCOUNT_ID",
})
This can then be used like other Fog DNS providers.
zone = dns.zones.create(
domain: "example.com"
)
record = zone.records.create(
name: "foo",
value: "1.2.3.4",
type: "A"
)
The following configurations are supported:
dns = Fog::DNS.new({
# Use dnsimple_url to provide a different base URL, e.g. the Sandbox URL
dnsimple_url: "https://api.sandbox.dnsimple.com/",
})
Contributing
- Fork it ( https://github.com/fog/fog-dnsimple/fork )
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request