Class: AwsUtils::Route53AddResourceRecord
- Inherits:
-
Object
- Object
- AwsUtils::Route53AddResourceRecord
- Defined in:
- lib/awsutils/r53addrr.rb
Instance Method Summary collapse
- #connection ⇒ Object
-
#initialize ⇒ Route53AddResourceRecord
constructor
A new instance of Route53AddResourceRecord.
- #parse_opts ⇒ Object
Constructor Details
#initialize ⇒ Route53AddResourceRecord
Returns a new instance of Route53AddResourceRecord.
20 21 22 |
# File 'lib/awsutils/r53addrr.rb', line 20 def initialize @opts = parse_opts end |
Instance Method Details
#connection ⇒ Object
7 8 9 |
# File 'lib/awsutils/r53addrr.rb', line 7 def connection @connection ||= Fog::DNS::AWS.new end |
#parse_opts ⇒ Object
11 12 13 14 15 16 17 18 |
# File 'lib/awsutils/r53addrr.rb', line 11 def parse_opts Optimist. do opt :name, 'The name', short: 'n', type: String, required: true opt :type, 'Record type (e.g. CNAME or A)', short: 'T', type: String, required: true opt :ttl, 'Time-to-live', short: 't', type: String, default: '300' opt :value, 'Record Value', short: 'v', type: String, required: true end end |