1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00
fog--fog/lib/fog/cdn/requests/rackspace/head_container.rb
2011-02-09 16:31:57 -08:00

33 lines
979 B
Ruby

module Fog
module Rackspace
class CDN
class Real
# List cdn properties for a container
#
# ==== Parameters
# * container<~String> - Name of container to retrieve info for
#
# ==== Returns
# * response<~Excon::Response>:
# * headers<~Hash>:
# * 'X-CDN-Enabled'<~Boolean> - cdn status for container
# * 'X-CDN-URI'<~String> - cdn url for this container
# * 'X-TTL'<~String> - integer seconds before data expires, defaults to 86400 (1 day)
# * 'X-Log-Retention'<~Boolean> - ?
# * 'X-User-Agent-ACL'<~String> - ?
# * 'X-Referrer-ACL'<~String> - ?
def head_container(container)
response = request(
:expects => 204,
:method => 'HEAD',
:path => container,
:query => {'format' => 'json'}
)
response
end
end
end
end
end