Skip to content
This repository has been archived by the owner on Nov 14, 2024. It is now read-only.

Commit

Permalink
Add backend bucket signed URL key (for CDN) support
Browse files Browse the repository at this point in the history
Signed-off-by: Modular Magician <[email protected]>
  • Loading branch information
emilymye authored and modular-magician committed Mar 13, 2019
1 parent 8b24d8b commit 412927f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions docs/resources/google_compute_backend_service.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ Properties that can be accessed from the `google_compute_backend_service` resour

* `cacheKeyPolicy`: The CacheKeyPolicy for this CdnPolicy.

* `signedUrlCacheMaxAgeSec`: Maximum number of seconds the response to a signed URL request will be considered fresh, defaults to 1hr (3600s). After this time period, the response will be revalidated before being served. When serving responses to signed URL requests, Cloud CDN will internally behave as though all responses from this backend had a "Cache-Control: public, max-age=[TTL]" header, regardless of any existing Cache-Control header. The actual headers served in responses will not be altered.

* `connection_draining`: Settings for connection draining

* `drainingTimeoutSec`: Time for which instance will be drained (not accept new connections, but still work to finish started).
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,12 @@ module Property
class BackendServiceCdnPolicy
attr_reader :cache_key_policy

attr_reader :signed_url_cache_max_age_sec

def initialize(args = nil)
return if args.nil?
@cache_key_policy = GoogleInSpec::Compute::Property::BackendServiceCdnPolicyCacheKeyPolicy.new(args['cacheKeyPolicy'])
@signed_url_cache_max_age_sec = args['signedUrlCacheMaxAgeSec']
end
end
end
Expand Down

0 comments on commit 412927f

Please sign in to comment.