mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
Merge pull request #683 from zacharydanger/master
Fixes the rackspace_cdn_ssl public_url method
This commit is contained in:
commit
f07e59472f
1 changed files with 5 additions and 1 deletions
|
@ -58,7 +58,11 @@ module Fog
|
|||
|
||||
if @connection.cdn && @public
|
||||
# if public and CDN connection then update cdn to public
|
||||
@public_url = connection.cdn.put_container(key, 'X-CDN-Enabled' => 'True').headers['X-CDN-URI']
|
||||
uri_header = 'X-CDN-URI'
|
||||
if connection.rackspace_cdn_ssl == true
|
||||
uri_header = 'X-CDN-SSL-URI'
|
||||
end
|
||||
@public_url = connection.cdn.put_container(key, 'X-CDN-Enabled' => 'True').headers[uri_header]
|
||||
elsif @connection.cdn && !@public
|
||||
connection.cdn.put_container(key, 'X-CDN-Enabled' => 'False')
|
||||
@public_url = nil
|
||||
|
|
Loading…
Reference in a new issue