Sha256: be079a63cd42b380081e0795379bf938f6f915bba8b784d9fe38f0049fbaa599

Contents?: true

Size: 482 Bytes

Versions: 4

Compression:

Stored size: 482 Bytes

Contents

require 'aws-sdk-cloudfront'

module TerraformDevKit
  module Aws
    class CloudFront 
      def initialize(credentials, region)
        @cloudfront = ::Aws::CloudFront::Client.new(
          region: region, 
          credentials:credentials
        )
      end

      def distribution_is_deployed?(distribution_id)
        @cloudfront.get_distribution({
          id: distribution_id, 
        }).distribution.status == 'Deployed'
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
TerraformDevKit-0.3.8 lib/TerraformDevKit/aws/cloudfront.rb
TerraformDevKit-0.3.3 lib/TerraformDevKit/aws/cloudfront.rb
TerraformDevKit-0.3.1 lib/TerraformDevKit/aws/cloudfront.rb
TerraformDevKit-0.3.1.pre.rc1 lib/TerraformDevKit/aws/cloudfront.rb