Class: Chef::Provider::AwsCloudsearchDomain
Constant Summary
Chef::Provisioning::AWSDriver::AWSProvider::AWSResource
Instance Attribute Summary
#purging
Instance Method Summary
collapse
#action_handler, #converge_by, #region, #whyrun_supported?
Instance Method Details
#create_aws_object ⇒ Object
6
7
8
9
10
11
12
13
14
15
16
17
18
|
# File 'lib/chef/provider/aws_cloudsearch_domain.rb', line 6
def create_aws_object
domain = nil
converge_by "create CloudSearch domain #{new_resource.name}" do
domain = create_domain
end
update_aws_object(domain)
create_index_fields
end
|
#destroy_aws_object(domain) ⇒ Object
20
21
22
23
24
25
26
|
# File 'lib/chef/provider/aws_cloudsearch_domain.rb', line 20
def destroy_aws_object(domain)
converge_by "delete CloudSearch domain #{new_resource.name}" do
cs_client.delete_domain(domain_name: new_resource.name)
end
end
|
#update_aws_object(domain) ⇒ Object
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
|
# File 'lib/chef/provider/aws_cloudsearch_domain.rb', line 28
def update_aws_object(domain)
if update_availability_options?(domain)
converge_by "update availability options for CloudSearch domain #{new_resource}" do
update_availability_options
end
end
if update_scaling_params?(domain)
converge_by "update scaling parameters for CloudSearch domain #{new_resource.name}" do
update_scaling_parameters
end
end
if update_policy?(domain)
converge_by "update access policy for CloudSearch domain #{new_resource.name}" do
update_service_access_policy
end
end
if update_index_fields?(domain)
Chef::Log.warn("Updating existing index_fields not currently supported")
end
end
|