1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00

[dns] refactor provider/service namespacing

This commit is contained in:
geemus 2011-06-15 17:25:01 -07:00
parent e1512c9ac8
commit a50f469778
154 changed files with 518 additions and 590 deletions

View file

@ -37,6 +37,7 @@ else
providers = Fog.providers
# FIXME: hacks until we can `include Fog` in bin
DNS = Fog::DNS
Storage = Fog::Storage
catch(:IRB_EXIT) { @irb.eval_input }

View file

@ -10,7 +10,7 @@ class AWS < Fog::Bin
when :compute
Fog::AWS::Compute
when :dns
Fog::AWS::DNS
Fog::DNS::AWS
when :elb
Fog::AWS::ELB
when :iam
@ -41,6 +41,7 @@ class AWS < Fog::Bin
when :compute
Fog::Compute.new(:provider => 'AWS')
when :dns
Formatador.display_line("[yellow][WARN] AWS[:dns] is deprecated, use DNS[:aws] instead[/]")
Fog::DNS.new(:provider => 'AWS')
when :elb
Fog::AWS::ELB.new

View file

@ -6,7 +6,7 @@ class Bluebox < Fog::Bin
when :compute
Fog::Bluebox::Compute
when :dns
Fog::Bluebox::DNS
Fog::DNS::Bluebox
else
raise ArgumentError, "Unsupported #{self} service: #{key}"
end
@ -18,6 +18,7 @@ class Bluebox < Fog::Bin
when :compute
Fog::Compute.new(:provider => 'Bluebox')
when :dns
Formatador.display_line("[yellow][WARN] Bluebox[:storage] is deprecated, use Storage[:bluebox] instead[/]")
Fog::DNS.new(:provider => 'Bluebox')
else
raise ArgumentError, "Unrecognized service: #{service}"

View file

@ -4,7 +4,7 @@ class DNSimple < Fog::Bin
def class_for(key)
case key
when :dns
Fog::DNSimple::DNS
Fog::DNS::DNSimple
else
raise ArgumentError, "Unrecognized service: #{key}"
end
@ -13,11 +13,12 @@ class DNSimple < Fog::Bin
def [](service)
@@connections ||= Hash.new do |hash, key|
hash[key] = case key
when :dns
Fog::DNS.new(:provider => 'DNSimple')
else
raise ArgumentError, "Unrecognized service: #{key.inspect}"
end
when :dns
Formatador.display_line("[yellow][WARN] DNSimple[:dns] is deprecated, use Storage[:dnsimple] instead[/]")
Fog::DNS.new(:provider => 'DNSimple')
else
raise ArgumentError, "Unrecognized service: #{key.inspect}"
end
end
@@connections[service]
end

View file

@ -4,7 +4,7 @@ class DNSMadeEasy < Fog::Bin
def class_for(key)
case key
when :dns
Fog::DNSMadeEasy::DNS
Fog::DNS::DNSMadeEasy
else
raise ArgumentError, "Unrecognized service: #{key}"
end
@ -13,11 +13,12 @@ class DNSMadeEasy < Fog::Bin
def [](service)
@@connections ||= Hash.new do |hash, key|
hash[key] = case key
when :dns
Fog::DNS.new(:provider => 'DNSMadeEasy')
else
raise ArgumentError, "Unrecognized service: #{key.inspect}"
end
when :dns
Formatador.display_line("[yellow][WARN] DNSMadeEasy[:dns] is deprecated, use Storage[:dnsmadeeasy] instead[/]")
Fog::DNS.new(:provider => 'DNSMadeEasy')
else
raise ArgumentError, "Unrecognized service: #{key.inspect}"
end
end
@@connections[service]
end

View file

@ -6,7 +6,7 @@ class Linode < Fog::Bin
when :compute
Fog::Linode::Compute
when :dns
Fog::Linode::DNS
Fog::DNS::Linode
else
raise ArgumentError, "Unsupported #{self} service: #{key}"
end
@ -18,6 +18,7 @@ class Linode < Fog::Bin
when :compute
Fog::Compute.new(:provider => 'Linode')
when :dns
Formatador.display_line("[yellow][WARN] Linode[:storage] is deprecated, use Storage[:linode] instead[/]")
Fog::DNS.new(:provider => 'Linode')
else
raise ArgumentError, "Unrecognized service: #{key.inspect}"

View file

@ -6,7 +6,7 @@ class Slicehost < Fog::Bin
when :compute
Fog::Slicehost::Compute
when :dns
Fog::Slicehost::DNS
Fog::DNS::Slicehost
else
raise ArgumentError, "Unrecognized service: #{key}"
end
@ -18,6 +18,7 @@ class Slicehost < Fog::Bin
when :compute
Fog::Compute.new(:provider => 'Slicehost')
when :dns
Formatador.display_line("[yellow][WARN] Slicehost[:dns] is deprecated, use Storage[:slicehost] instead[/]")
Fog::DNS.new(:provider => 'Slicehost')
else
raise ArgumentError, "Unrecognized service: #{key.inspect}"

View file

@ -4,7 +4,7 @@ class Zerigo < Fog::Bin
def class_for(key)
case key
when :dns
Fog::Zerigo::DNS
Fog::DNS::Zerigo
else
raise ArgumentError, "Unrecognized service: #{key}"
end
@ -14,6 +14,7 @@ class Zerigo < Fog::Bin
@@connections ||= Hash.new do |hash, key|
hash[key] = case key
when :dns
Formatador.display_line("[yellow][WARN] Zerigo[:dns] is deprecated, use Storage[:zerigo] instead[/]")
Fog::DNS.new(:provider => 'Zerigo')
else
raise ArgumentError, "Unrecognized service: #{key.inspect}"

View file

@ -1,34 +1,49 @@
module Fog
class DNS
module DNS
def self.[](provider)
self.new(:provider => provider)
end
def self.new(attributes)
attributes = attributes.dup # prevent delete from having side effects
case provider = attributes[:provider] # attributes.delete(:provider)
when 'AWS'
case provider = attributes[:provider].to_s.downcase.to_sym
when :aws
require 'fog/dns/aws'
Fog::AWS::DNS.new(attributes)
when 'Bluebox'
Fog::DNS::AWS.new(attributes)
when :bluebox
require 'fog/dns/bluebox'
Fog::Bluebox::DNS.new(attributes)
when 'DNSimple'
Fog::DNS::Bluebox.new(attributes)
when :dnsimple
require 'fog/dns/dnsimple'
Fog::DNSimple::DNS.new(attributes)
when 'DNSMadeEasy'
Fog::DNS::DNSimple.new(attributes)
when :dnsmadeeasy
require 'fog/dns/dnsmadeeasy'
Fog::DNSMadeEasy::DNS.new(attributes)
when 'Linode'
Fog::DNS::DNSMadeEasy.new(attributes)
when :linode
require 'fog/dns/linode'
Fog::Linode::DNS.new(attributes)
when 'Slicehost'
Fog::DNS::Linode.new(attributes)
when :slicehost
require 'fog/dns/slicehost'
Fog::Slicehost::DNS.new(attributes)
when 'Zerigo'
Fog::DNS::Slicehost.new(attributes)
when :zerigo
require 'fog/dns/zerigo'
Fog::Zerigo::DNS.new(attributes)
Fog::DNS::Zerigo.new(attributes)
else
raise ArgumentError.new("#{provider} is not a recognized dns provider")
end
end
def self.zones
zones = []
for provider in [:aws, :bluebox, :dnsimple, :dnsmadeeasy, :linode, :slicehost, :zerigo]
begin
zones.concat(self[provider].zones)
rescue # ignore any missing credentials/etc
end
end
zones
end
end
end

View file

@ -1,6 +1,6 @@
module Fog
module AWS
class DNS < Fog::Service
module DNS
class AWS < Fog::Service
requires :aws_access_key_id, :aws_secret_access_key
recognizes :host, :path, :port, :scheme, :version, :persistent
@ -38,13 +38,6 @@ module Fog
end
def initialize(options={})
unless options.delete(:provider)
location = caller.first
warning = "[yellow][WARN] Fog::AWS::DNS.new is deprecated, use Fog::DNS.new(:provider => 'AWS') instead[/]"
warning << " [light_black](" << location << ")[/] "
Formatador.display_line(warning)
end
require 'mime/types'
@aws_access_key_id = options[:aws_access_key_id]
@region = options[:region]
@ -83,13 +76,6 @@ module Fog
# ==== Returns
# * dns object with connection to aws.
def initialize(options={})
unless options.delete(:provider)
location = caller.first
warning = "[yellow][WARN] Fog::AWS::DNS.new is deprecated, use Fog::DNS.new(:provider => 'DNS') instead[/]"
warning << " [light_black](" << location << ")[/] "
Formatador.display_line(warning)
end
require 'fog/core/parser'
@aws_access_key_id = options[:aws_access_key_id]

View file

@ -1,6 +1,6 @@
module Fog
module Bluebox
class DNS < Fog::Service
module DNS
class Bluebox < Fog::Service
requires :bluebox_api_key, :bluebox_customer_id
recognizes :bluebox_host, :bluebox_port, :bluebox_scheme, :persistent
recognizes :provider # remove post deprecation
@ -35,13 +35,6 @@ module Fog
end
def initialize(options={})
unless options.delete(:provider)
location = caller.first
warning = "[yellow][WARN] Fog::Bluebox::DNS.new is deprecated, use Fog::DNS.new(:provider => 'Bluebox') instead[/]"
warning << " [light_black](" << location << ")[/] "
Formatador.display_line(warning)
end
@bluebox_customer_id = options[:bluebox_customer_id]
@bluebox_api_key = options[:bluebox_api_key]
end
@ -57,13 +50,6 @@ module Fog
class Real
def initialize(options ={})
unless options.delete(:provider)
location = caller.first
warning = "[yellow][WARN] Fog::Bluebox::DNS.new is deprecated, use Fog::DNS.new(:provider => 'Bluebox') instead[/]"
warning << " [light_black](" << location << ")[/] "
Formatador.display_line(warning)
end
@bluebox_customer_id = options[:bluebox_customer_id]
@bluebox_api_key = options[:bluebox_api_key]
@ -93,7 +79,7 @@ module Fog
rescue Excon::Errors::HTTPStatusError => error
raise case error
when Excon::Errors::NotFound
Fog::Bluebox::DNS::NotFound.slurp(error)
Fog::DNS::Bluebox::NotFound.slurp(error)
else
error
end

View file

@ -1,6 +1,6 @@
module Fog
module DNSimple
class DNS < Fog::Service
module DNS
class DNSimple < Fog::Service
requires :dnsimple_email, :dnsimple_password
recognizes :dnsimple_url, :host, :path, :port, :scheme, :persistent
@ -36,13 +36,6 @@ module Fog
end
def initialize(options={})
unless options.delete(:provider)
location = caller.first
warning = "[yellow][WARN] Fog::DNS::DNSimple.new is deprecated, use Fog::DNS.new(:provider => 'DNSimple') instead[/]"
warning << " [light_black](" << location << ")[/] "
Formatador.display_line(warning)
end
@dnsimple_email = options[:dnsimple_email]
@dnsimple_password = options[:dnsimple_password]
end
@ -60,13 +53,6 @@ module Fog
class Real
def initialize(options={})
unless options.delete(:provider)
location = caller.first
warning = "[yellow][WARN] Fog::DNSimple::DNS.new is deprecated, use Fog::DNS.new(:provider => 'DNSimple') instead[/]"
warning << " [light_black](" << location << ")[/] "
Formatador.display_line(warning)
end
require 'json'
@dnsimple_email = options[:dnsimple_email]

View file

@ -1,6 +1,6 @@
module Fog
module DNSMadeEasy
class DNS < Fog::Service
module DNS
class DNSMadeEasy < Fog::Service
requires :dnsmadeeasy_api_key, :dnsmadeeasy_secret_key
recognizes :host, :path, :port, :scheme, :persistent
@ -44,13 +44,6 @@ module Fog
end
def initialize(options={})
unless options.delete(:provider)
location = caller.first
warning = "[yellow][WARN] Fog::DNSMadeEasy::DNS.new is deprecated, use Fog::DNS.new(:provider => 'DNSMadeEasy') instead[/]"
warning << " [light_black](" << location << ")[/] "
Formatador.display_line(warning)
end
@dnsmadeeasy_api_key = options[:dnsmadeeasy_api_key]
@dnsmadeeasy_secret_key = options[:dnsmadeeasy_secret_key]
end
@ -84,13 +77,6 @@ module Fog
# ==== Returns
# * dns object with connection to aws.
def initialize(options={})
unless options.delete(:provider)
location = caller.first
warning = "[yellow][WARN] Fog::DNSMadeEasy::DNS.new is deprecated, use Fog::DNS.new(:provider => 'DNSMadeEasy') instead[/]"
warning << " [light_black](" << location << ")[/] "
Formatador.display_line(warning)
end
require 'fog/core/parser'
require 'json'
@ -125,7 +111,7 @@ module Fog
rescue Excon::Errors::HTTPStatusError => error
raise case error
when Excon::Errors::NotFound
Fog::DNSMadeEasy::DNS::NotFound.slurp(error)
Fog::DNS::DNSMadeEasy::NotFound.slurp(error)
else
error
end

View file

@ -1,6 +1,6 @@
module Fog
module Linode
class DNS < Fog::Service
module DNS
class Linode < Fog::Service
requires :linode_api_key
recognizes :port, :scheme, :persistent
@ -35,13 +35,6 @@ module Fog
end
def initialize(options={})
unless options.delete(:provider)
location = caller.first
warning = "[yellow][WARN] Fog::Linode::DNS.new is deprecated, use Fog::DNS.new(:provider => 'Linode') instead[/]"
warning << " [light_black](" << location << ")[/] "
Formatador.display_line(warning)
end
@linode_api_key = options[:linode_api_key]
end
@ -58,13 +51,6 @@ module Fog
class Real
def initialize(options={})
unless options.delete(:provider)
location = caller.first
warning = "[yellow][WARN] Fog::Linode::DNS.new is deprecated, use Fog::DNS.new(:provider => 'Linode') instead[/]"
warning << " [light_black](" << location << ")[/] "
Formatador.display_line(warning)
end
require 'json'
@linode_api_key = options[:linode_api_key]
@host = options[:host] || "api.linode.com"
@ -88,9 +74,9 @@ module Fog
if data = response.body['ERRORARRAY'].first
error = case data['ERRORCODE']
when 5
Fog::Linode::DNS::NotFound
Fog::DNS::Linode::NotFound
else
Fog::Linode::DNS::Error
Fog::DNS::Linode::Error
end
raise error.new(data['ERRORMESSAGE'])
end

View file

@ -1,8 +1,8 @@
require 'fog/core/model'
module Fog
module AWS
class DNS
module DNS
class AWS
class Record < Fog::Model
extend Fog::Deprecation

View file

@ -2,8 +2,8 @@ require 'fog/core/collection'
require 'fog/dns/models/aws/record'
module Fog
module AWS
class DNS
module DNS
class AWS
class Records < Fog::Collection
@ -16,7 +16,7 @@ module Fog
attribute :zone
model Fog::AWS::DNS::Record
model Fog::DNS::AWS::Record
def all(options = {})
requires :zone

View file

@ -2,8 +2,8 @@ require 'fog/core/model'
# require 'fog/dns/models/aws/records'
module Fog
module AWS
class DNS
module DNS
class AWS
class Zone < Fog::Model
@ -23,7 +23,7 @@ module Fog
def records
@records ||= begin
Fog::AWS::DNS::Records.new(
Fog::DNS::AWS::Records.new(
:zone => self,
:connection => connection
)

View file

@ -2,15 +2,15 @@ require 'fog/core/collection'
require 'fog/dns/models/aws/zone'
module Fog
module AWS
class DNS
module DNS
class AWS
class Zones < Fog::Collection
attribute :marker, :aliases => 'Marker'
attribute :max_items, :aliases => 'MaxItems'
model Fog::AWS::DNS::Zone
model Fog::DNS::AWS::Zone
def all(options = {})
options['marker'] ||= marker

View file

@ -1,8 +1,8 @@
require 'fog/core/model'
module Fog
module Bluebox
class DNS
module DNS
class Bluebox
class Record < Fog::Model
extend Fog::Deprecation

View file

@ -2,14 +2,14 @@ require 'fog/core/collection'
require 'fog/dns/models/bluebox/record'
module Fog
module Bluebox
class DNS
module DNS
class Bluebox
class Records < Fog::Collection
attribute :zone
model Fog::Bluebox::DNS::Record
model Fog::DNS::Bluebox::Record
def all
requires :zone

View file

@ -2,8 +2,8 @@ require 'fog/core/model'
require 'fog/dns/models/bluebox/records'
module Fog
module Bluebox
class DNS
module DNS
class Bluebox
class Zone < Fog::Model
@ -29,7 +29,7 @@ module Fog
def records
@records ||= begin
Fog::Bluebox::DNS::Records.new(
Fog::DNS::Bluebox::Records.new(
:zone => self,
:connection => connection
)

View file

@ -2,12 +2,12 @@ require 'fog/core/collection'
require 'fog/dns/models/bluebox/zone'
module Fog
module Bluebox
class DNS
module DNS
class Bluebox
class Zones < Fog::Collection
model Fog::Bluebox::DNS::Zone
model Fog::DNS::Bluebox::Zone
def all
data = connection.get_zones.body['zones']

View file

@ -1,8 +1,8 @@
require 'fog/core/model'
module Fog
module DNSimple
class DNS
module DNS
class DNSimple
class Record < Fog::Model
extend Fog::Deprecation

View file

@ -2,14 +2,14 @@ require 'fog/core/collection'
require 'fog/dns/models/dnsimple/record'
module Fog
module DNSimple
class DNS
module DNS
class DNSimple
class Records < Fog::Collection
attribute :zone
model Fog::DNSimple::DNS::Record
model Fog::DNS::DNSimple::Record
def all
requires :zone

View file

@ -2,8 +2,8 @@ require 'fog/core/model'
require 'fog/dns/models/dnsimple/records'
module Fog
module DNSimple
class DNS
module DNS
class DNSimple
class Zone < Fog::Model
@ -20,11 +20,11 @@ module Fog
def records
@records ||= begin
Fog::DNSimple::DNS::Records.new(
:zone => self,
:connection => connection
)
end
Fog::DNS::DNSimple::Records.new(
:zone => self,
:connection => connection
)
end
end
def nameservers

View file

@ -2,12 +2,12 @@ require 'fog/core/collection'
require 'fog/dns/models/dnsimple/zone'
module Fog
module DNSimple
class DNS
module DNS
class DNSimple
class Zones < Fog::Collection
model Fog::DNSimple::DNS::Zone
model Fog::DNS::DNSimple::Zone
def all
clear

View file

@ -1,8 +1,8 @@
require 'fog/core/model'
module Fog
module DNSMadeEasy
class DNS
module DNS
class DNSMadeEasy
class Record < Fog::Model
extend Fog::Deprecation

View file

@ -2,14 +2,14 @@ require 'fog/core/collection'
require 'fog/dns/models/dnsmadeeasy/record'
module Fog
module DNSMadeEasy
class DNS
module DNS
class DNSMadeEasy
class Records < Fog::Collection
attribute :zone
model Fog::DNSMadeEasy::DNS::Record
model Fog::DNS::DNSMadeEasy::Record
def all
requires :zone

View file

@ -2,8 +2,8 @@ require 'fog/core/model'
require 'fog/dns/models/dnsmadeeasy/records'
module Fog
module DNSMadeEasy
class DNS
module DNS
class DNSMadeEasy
class Zone < Fog::Model
@ -20,7 +20,7 @@ module Fog
def records
@records ||= begin
Fog::DNSMadeEasy::DNS::Records.new(
Fog::DNS::DNSMadeEasy::Records.new(
:zone => self,
:connection => connection
)

View file

@ -2,12 +2,12 @@ require 'fog/core/collection'
require 'fog/dns/models/dnsmadeeasy/zone'
module Fog
module DNSMadeEasy
class DNS
module DNS
class DNSMadeEasy
class Zones < Fog::Collection
model Fog::DNSMadeEasy::DNS::Zone
model Fog::DNS::DNSMadeEasy::Zone
def all
clear

View file

@ -1,8 +1,8 @@
require 'fog/core/model'
module Fog
module Linode
class DNS
module DNS
class Linode
class Record < Fog::Model
extend Fog::Deprecation

View file

@ -2,14 +2,14 @@ require 'fog/core/collection'
require 'fog/dns/models/linode/record'
module Fog
module Linode
class DNS
module DNS
class Linode
class Records < Fog::Collection
attribute :zone
model Fog::Linode::DNS::Record
model Fog::DNS::Linode::Record
def all
requires :zone

View file

@ -2,8 +2,8 @@ require 'fog/core/model'
require 'fog/dns/models/linode/records'
module Fog
module Linode
class DNS
module DNS
class Linode
class Zone < Fog::Model
@ -36,7 +36,7 @@ module Fog
def records
@records ||= begin
Fog::Linode::DNS::Records.new(
Fog::DNS::Linode::Records.new(
:zone => self,
:connection => connection
)

View file

@ -2,12 +2,12 @@ require 'fog/core/collection'
require 'fog/dns/models/linode/zone'
module Fog
module Linode
class DNS
module DNS
class Linode
class Zones < Fog::Collection
model Fog::Linode::DNS::Zone
model Fog::DNS::Linode::Zone
def all
data = connection.domain_list.body['DATA']

View file

@ -1,8 +1,8 @@
require 'fog/core/model'
module Fog
module Slicehost
class DNS
module DNS
class Slicehost
class Record < Fog::Model
extend Fog::Deprecation

View file

@ -2,14 +2,14 @@ require 'fog/core/collection'
require 'fog/dns/models/slicehost/record'
module Fog
module Slicehost
class DNS
module DNS
class Slicehost
class Records < Fog::Collection
attribute :zone
model Fog::Slicehost::DNS::Record
model Fog::DNS::Slicehost::Record
def all
requires :zone

View file

@ -2,8 +2,8 @@ require 'fog/core/model'
require 'fog/dns/models/slicehost/records'
module Fog
module Slicehost
class DNS
module DNS
class Slicehost
class Zone < Fog::Model
@ -36,7 +36,7 @@ module Fog
def records
@records ||= begin
Fog::Slicehost::DNS::Records.new(
Fog::DNS::Slicehost::Records.new(
:zone => self,
:connection => connection
)

View file

@ -2,12 +2,12 @@ require 'fog/core/collection'
require 'fog/dns/models/slicehost/zone'
module Fog
module Slicehost
class DNS
module DNS
class Slicehost
class Zones < Fog::Collection
model Fog::Slicehost::DNS::Zone
model Fog::DNS::Slicehost::Zone
def all
data = connection.get_zones.body['zones']

View file

@ -1,8 +1,8 @@
require 'fog/core/model'
module Fog
module Zerigo
class DNS
module DNS
class Zerigo
class Record < Fog::Model
extend Fog::Deprecation

View file

@ -2,14 +2,14 @@ require 'fog/core/collection'
require 'fog/dns/models/zerigo/record'
module Fog
module Zerigo
class DNS
module DNS
class Zerigo
class Records < Fog::Collection
attribute :zone
model Fog::Zerigo::DNS::Record
model Fog::DNS::Zerigo::Record
def all
requires :zone

View file

@ -2,8 +2,8 @@ require 'fog/core/model'
require 'fog/dns/models/zerigo/records'
module Fog
module Zerigo
class DNS
module DNS
class Zerigo
class Zone < Fog::Model
@ -39,7 +39,7 @@ module Fog
def records
@records ||= begin
Fog::Zerigo::DNS::Records.new(
Fog::DNS::Zerigo::Records.new(
:zone => self,
:connection => connection
)

View file

@ -2,12 +2,12 @@ require 'fog/core/collection'
require 'fog/dns/models/zerigo/zone'
module Fog
module Zerigo
class DNS
module DNS
class Zerigo
class Zones < Fog::Collection
model Fog::Zerigo::DNS::Zone
model Fog::DNS::Zerigo::Zone
def all
data = connection.list_zones.body['zones']

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module AWS
module DNS
module DNS
module AWS
class ChangeResourceRecordSets < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module AWS
module DNS
module DNS
module AWS
class CreateHostedZone < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module AWS
module DNS
module DNS
module AWS
class DeleteHostedZone < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module AWS
module DNS
module DNS
module AWS
class GetChange < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module AWS
module DNS
module DNS
module AWS
class GetHostedZone < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module AWS
module DNS
module DNS
module AWS
class ListHostedZones < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module AWS
module DNS
module DNS
module AWS
class ListResourceRecordSets < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Bluebox
module DNS
module DNS
module Bluebox
class CreateRecord < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Bluebox
module DNS
module DNS
module Bluebox
class CreateZone < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Bluebox
module DNS
module DNS
module Bluebox
class GetRecord < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Bluebox
module DNS
module DNS
module Bluebox
class GetRecords < Fog::Parsers::Base
@ -19,6 +19,7 @@ module Fog
@record[name] = value
end
end
end
end

View file

@ -1,7 +1,8 @@
module Fog
module Parsers
module Bluebox
module DNS
module DNS
module Bluebox
class GetZone < Fog::Parsers::Base
def reset
@ -16,7 +17,9 @@ module Fog
@response[name] = value
end
end
end
end
end
end

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Bluebox
module DNS
module DNS
module Bluebox
class GetZones < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Slicehost
module DNS
module DNS
module Slicehost
class CreateRecord < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Slicehost
module DNS
module DNS
module Slicehost
class CreateZone < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Slicehost
module DNS
module DNS
module Slicehost
class GetRecord < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Slicehost
module DNS
module DNS
module Slicehost
class GetRecords < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Slicehost
module DNS
module DNS
module Slicehost
class GetZone < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Slicehost
module DNS
module DNS
module Slicehost
class GetZones < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Zerigo
module DNS
module DNS
module Zerigo
class CountHosts < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Zerigo
module DNS
module DNS
module Zerigo
class CountZones < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Zerigo
module DNS
module DNS
module Zerigo
class CreateHost < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Zerigo
module DNS
module DNS
module Zerigo
class CreateZone < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Zerigo
module DNS
module DNS
module Zerigo
class FindHosts < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Zerigo
module DNS
module DNS
module Zerigo
class GetHost < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Zerigo
module DNS
module DNS
module Zerigo
class GetZone < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Zerigo
module DNS
module DNS
module Zerigo
class GetZoneStats < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Zerigo
module DNS
module DNS
module Zerigo
class ListHosts < Fog::Parsers::Base

View file

@ -1,7 +1,7 @@
module Fog
module Parsers
module Zerigo
module DNS
module DNS
module Zerigo
class ListZones < Fog::Parsers::Base

View file

@ -1,6 +1,6 @@
module Fog
module AWS
class DNS
module DNS
class AWS
class Real
require 'fog/dns/parsers/aws/change_resource_record_sets'
@ -68,7 +68,7 @@ module Fog
body = %Q{<?xml version="1.0" encoding="UTF-8"?><ChangeResourceRecordSetsRequest xmlns="https://route53.amazonaws.com/doc/2010-10-01/">#{changes}</ChangeResourceRecordSetsRequest>}
request({
:body => body,
:parser => Fog::Parsers::AWS::DNS::ChangeResourceRecordSets.new,
:parser => Fog::Parsers::DNS::AWS::ChangeResourceRecordSets.new,
:expects => 200,
:method => 'POST',
:path => "hostedzone/#{zone_id}/rrset"

View file

@ -1,6 +1,6 @@
module Fog
module AWS
class DNS
module DNS
class AWS
class Real
require 'fog/dns/parsers/aws/create_hosted_zone'
@ -45,7 +45,7 @@ module Fog
request({
:body => %Q{<?xml version="1.0" encoding="UTF-8"?><CreateHostedZoneRequest xmlns="https://route53.amazonaws.com/doc/2010-10-01/"><Name>#{name}</Name>#{optional_tags}</CreateHostedZoneRequest>},
:parser => Fog::Parsers::AWS::DNS::CreateHostedZone.new,
:parser => Fog::Parsers::DNS::AWS::CreateHostedZone.new,
:expects => 201,
:method => 'POST',
:path => "hostedzone"

View file

@ -1,6 +1,6 @@
module Fog
module AWS
class DNS
module DNS
class AWS
class Real
require 'fog/dns/parsers/aws/delete_hosted_zone'
@ -26,7 +26,7 @@ module Fog
request({
:expects => 200,
:parser => Fog::Parsers::AWS::DNS::DeleteHostedZone.new,
:parser => Fog::Parsers::DNS::AWS::DeleteHostedZone.new,
:method => 'DELETE',
:path => "hostedzone/#{zone_id}"
})

View file

@ -1,6 +1,6 @@
module Fog
module AWS
class DNS
module DNS
class AWS
class Real
require 'fog/dns/parsers/aws/get_change'
@ -25,7 +25,7 @@ module Fog
request({
:expects => 200,
:parser => Fog::Parsers::AWS::DNS::GetChange.new,
:parser => Fog::Parsers::DNS::AWS::GetChange.new,
:method => 'GET',
:path => "change/#{change_id}"
})

View file

@ -1,6 +1,6 @@
module Fog
module AWS
class DNS
module DNS
class AWS
class Real
require 'fog/dns/parsers/aws/get_hosted_zone'
@ -29,7 +29,7 @@ module Fog
request({
:expects => 200,
:parser => Fog::Parsers::AWS::DNS::GetHostedZone.new,
:parser => Fog::Parsers::DNS::AWS::GetHostedZone.new,
:method => 'GET',
:path => "hostedzone/#{zone_id}"
})

View file

@ -1,6 +1,6 @@
module Fog
module AWS
class DNS
module DNS
class AWS
class Real
require 'fog/dns/parsers/aws/list_hosted_zones'
@ -40,7 +40,7 @@ module Fog
request({
:query => parameters,
:parser => Fog::Parsers::AWS::DNS::ListHostedZones.new,
:parser => Fog::Parsers::DNS::AWS::ListHostedZones.new,
:expects => 200,
:method => 'GET',
:path => "hostedzone"

View file

@ -1,6 +1,6 @@
module Fog
module AWS
class DNS
module DNS
class AWS
class Real
require 'fog/dns/parsers/aws/list_resource_record_sets'
@ -46,7 +46,7 @@ module Fog
request({
:query => parameters,
:parser => Fog::Parsers::AWS::DNS::ListResourceRecordSets.new,
:parser => Fog::Parsers::DNS::AWS::ListResourceRecordSets.new,
:expects => 200,
:method => 'GET',
:path => "hostedzone/#{zone_id}/rrset"

View file

@ -1,6 +1,6 @@
module Fog
module Bluebox
class DNS
module DNS
class Bluebox
class Real
require 'fog/dns/parsers/bluebox/create_record'
@ -29,7 +29,7 @@ module Fog
:body => body,
:expects => 202,
:method => 'POST',
:parser => Fog::Parsers::Bluebox::DNS::CreateRecord.new,
:parser => Fog::Parsers::DNS::Bluebox::CreateRecord.new,
:path => "/api/domains/#{zone_id}/records.xml"
)
end

View file

@ -1,6 +1,6 @@
module Fog
module Bluebox
class DNS
module DNS
class Bluebox
class Real
require 'fog/dns/parsers/bluebox/create_zone'
@ -33,7 +33,7 @@ module Fog
:body => body,
:expects => 202,
:method => 'POST',
:parser => Fog::Parsers::Bluebox::DNS::CreateZone.new,
:parser => Fog::Parsers::DNS::Bluebox::CreateZone.new,
:path => "/api/domains.xml"
)
end

View file

@ -1,6 +1,6 @@
module Fog
module Bluebox
class DNS
module DNS
class Bluebox
class Real
# Delete a record from the specified DNS zone

View file

@ -1,6 +1,6 @@
module Fog
module Bluebox
class DNS
module DNS
class Bluebox
class Real
# Delete a zone from DNS

View file

@ -1,6 +1,6 @@
module Fog
module Bluebox
class DNS
module DNS
class Bluebox
class Real
require 'fog/dns/parsers/bluebox/get_record'
@ -21,7 +21,7 @@ module Fog
request(
:expects => 200,
:method => 'GET',
:parser => Fog::Parsers::Bluebox::DNS::GetRecord.new,
:parser => Fog::Parsers::DNS::Bluebox::GetRecord.new,
:path => "/api/domains/#{zone_id}/records/#{record_id}.xml"
)
end

View file

@ -1,6 +1,6 @@
module Fog
module Bluebox
class DNS
module DNS
class Bluebox
class Real
require 'fog/dns/parsers/bluebox/get_records'
@ -22,7 +22,7 @@ module Fog
request(
:expects => 200,
:method => 'GET',
:parser => Fog::Parsers::Bluebox::DNS::GetRecords.new,
:parser => Fog::Parsers::DNS::Bluebox::GetRecords.new,
:path => "/api/domains/#{zone_id}/records.xml"
)
end

View file

@ -1,6 +1,6 @@
module Fog
module Bluebox
class DNS
module DNS
class Bluebox
class Real
require 'fog/dns/parsers/bluebox/get_zone'
@ -25,7 +25,7 @@ module Fog
request(
:expects => 200,
:method => 'GET',
:parser => Fog::Parsers::Bluebox::DNS::GetZone.new,
:parser => Fog::Parsers::DNS::Bluebox::GetZone.new,
:path => "/api/domains/#{zone_id}.xml"
)
end

View file

@ -1,6 +1,6 @@
module Fog
module Bluebox
class DNS
module DNS
class Bluebox
class Real
require 'fog/dns/parsers/bluebox/get_zones'
@ -24,7 +24,7 @@ module Fog
request(
:expects => 200,
:method => 'GET',
:parser => Fog::Parsers::Bluebox::DNS::GetZones.new,
:parser => Fog::Parsers::DNS::Bluebox::GetZones.new,
:path => '/api/domains.xml'
)
end

View file

@ -1,6 +1,6 @@
module Fog
module Bluebox
class DNS
module DNS
class Bluebox
class Real
# Updates an existing DNS zone

View file

@ -1,6 +1,6 @@
module Fog
module DNSimple
class DNS
module DNS
class DNSimple
class Real
# Create a single domain in DNSimple in your account.

View file

@ -1,6 +1,6 @@
module Fog
module DNSimple
class DNS
module DNS
class DNSimple
class Real
# Create a new host in the specified zone

View file

@ -1,6 +1,6 @@
module Fog
module DNSimple
class DNS
module DNS
class DNSimple
class Real
# Delete the given domain from your account. You may use

View file

@ -1,6 +1,6 @@
module Fog
module DNSimple
class DNS
module DNS
class DNSimple
class Real
# Delete the record with the given ID for the given domain.

View file

@ -1,6 +1,6 @@
module Fog
module DNSimple
class DNS
module DNS
class DNSimple
class Real
# Get the details for a specific domain in your account. You

View file

@ -1,6 +1,6 @@
module Fog
module DNSimple
class DNS
module DNS
class DNSimple
class Real
# Gets record from given domain.

View file

@ -1,6 +1,6 @@
module Fog
module DNSimple
class DNS
module DNS
class DNSimple
class Real
# Get the details for a specific domain in your account. You

View file

@ -1,6 +1,6 @@
module Fog
module DNSimple
class DNS
module DNS
class DNSimple
class Real
# Get the list of records for the specific domain.

View file

@ -1,6 +1,6 @@
module Fog
module DNSimple
class DNS
module DNS
class DNSimple
class Real
# Update the given record for the given domain.

View file

@ -1,6 +1,6 @@
module Fog
module DNSMadeEasy
class DNS
module DNS
class DNSMadeEasy
class Real
# Creates a domain entry with the specified name. Returns errors if name is not valid or conflicts with another domain.

View file

@ -1,6 +1,6 @@
module Fog
module DNSMadeEasy
class DNS
module DNS
class DNSMadeEasy
class Real
# Creates a record with the representation specified in the request content. Returns errors if record is not valid.

View file

@ -1,6 +1,6 @@
module Fog
module DNSMadeEasy
class DNS
module DNS
class DNSMadeEasy
class Real
# Creates a secondary entry with the specified name. Returns errors if name is not valid or conflicts with another domain.

View file

@ -1,6 +1,6 @@
module Fog
module DNSMadeEasy
class DNS
module DNS
class DNSMadeEasy
class Real
# Deletes all domains for your account.

Some files were not shown because too many files have changed in this diff Show more