Class: Qurd::Action::Route53
- Inherits:
-
Qurd::Action
- Object
- Qurd::Action
- Qurd::Action::Route53
- Defined in:
- lib/qurd/action/route53.rb
Overview
Clean up route53 records
Defined Under Namespace
Classes: Errors
Instance Attribute Summary
Attributes inherited from Qurd::Action
Class Method Summary collapse
-
.configure(_action) ⇒ Object
Verify each
auto_scaling_queue
has a correspondingroute53
key and that each of those keys defines ahosted_zone
.
Instance Method Summary collapse
-
#terminate ⇒ Object
Delete the record, if the message did not fail other processing steps and dry_run is not true.
-
#test ⇒ Object
Respond to test actions.
Methods inherited from Qurd::Action
#aws_credentials, #initialize, #inspect, #launch, #region, #run_after, #run_before
Methods included from Mixins::Configuration
#qurd_config, #qurd_configuration, #qurd_logger, #qurd_logger!
Methods included from Mixins::AwsClients
Constructor Details
This class inherits a constructor from Qurd::Action
Class Method Details
.configure(_action) ⇒ Object
Verify each auto_scaling_queue
has a corresponding route53
key and that each of those keys defines a hosted_zone
32 33 34 35 36 |
# File 'lib/qurd/action/route53.rb', line 32 def self.configure(_action) return if @configure_done check_configuration @configure_done = true end |
Instance Method Details
#terminate ⇒ Object
Delete the record, if the message did not fail other processing steps and dry_run is not true
41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 |
# File 'lib/qurd/action/route53.rb', line 41 def terminate if .failed? qurd_logger.warn('Not deleting, message failed to process') elsif qurd_configuration.dry_run if !hosted_zone qurd_logger.debug('Dry run; missing hosted_zone') elsif !hostname qurd_logger.debug('Dry run; missing hostname') elsif !resource_record qurd_logger.debug('Dry run; missing resource_record') else qurd_logger.debug('Dry run; would delete') end else route53_delete end end |
#test ⇒ Object
Respond to test actions
60 61 62 |
# File 'lib/qurd/action/route53.rb', line 60 def test qurd_logger.info('Test') end |