1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00

Merge pull request #3374 from engineyard/rds-storage-type

add storage_type to rds server
This commit is contained in:
Wesley Beary 2014-12-30 17:12:09 -05:00
commit e49032fee8
3 changed files with 7 additions and 3 deletions

View file

@ -31,6 +31,7 @@ module Fog
attribute :db_subnet_group_name, :aliases => 'DBSubnetGroupName'
attribute :publicly_accessible, :aliases => 'PubliclyAccessible'
attribute :vpc_security_groups, :aliases => 'VpcSecurityGroups', :type => :array
attribute :storage_type, :aliases => 'StorageType'
attr_accessor :password, :parameter_group_name, :security_group_names, :port
@ -130,6 +131,7 @@ module Fog
'DBSubnetGroupName' => db_subnet_group_name,
'PubliclyAccessible' => publicly_accessible,
'VpcSecurityGroups' => vpc_security_groups,
'StorageType' => storage_type,
}
options.delete_if {|key, value| value.nil?}

View file

@ -43,10 +43,10 @@ module Fog
when 'LatestRestorableTime', 'InstanceCreateTime'
@db_instance[name] = Time.parse value
when 'Engine', 'DBInstanceStatus', 'DBInstanceIdentifier',
when 'Engine', 'DBInstanceStatus', 'DBInstanceIdentifier',
'PreferredBackupWindow', 'PreferredMaintenanceWindow',
'AvailabilityZone', 'MasterUsername', 'DBName', 'LicenseModel',
'DBSubnetGroupName'
'DBSubnetGroupName', 'StorageType'
@db_instance[name] = value
when 'MultiAZ', 'AutoMinorVersionUpgrade', 'PubliclyAccessible'
if value == 'false'
@ -71,7 +71,7 @@ module Fog
else
@db_instance[name] = value.to_i
end
when 'DBInstanceClass', 'EngineVersion', 'MasterUserPassword',
when 'DBInstanceClass', 'EngineVersion', 'MasterUserPassword',
'MultiAZ', 'Iops', 'AllocatedStorage'
if @in_pending_modified_values
@pending_modified_values[name] = value

View file

@ -27,6 +27,7 @@ module Fog
# @param DBSubnetGroupName [String] The name, if any, of the VPC subnet for this RDS instance
# @param PubliclyAcccesible [Boolean] Whether an RDS instance inside of the VPC subnet should have a public-facing endpoint
# @param VpcSecurityGroups [Array] A list of VPC Security Groups to authorize on this DB instance
# @param StorageType [string] Specifies storage type to be associated with the DB Instance. Valid values: standard | gp2 | io1
#
# @return [Excon::Response]:
# * body [Hash]:
@ -110,6 +111,7 @@ module Fog
"DBSubnetGroupName" => options["DBSubnetGroupName"],
"PubliclyAccessible" => options["PubliclyAccessible"],
"VpcSecurityGroups" => options["VpcSecurityGroups"],
"StorageType" => options["StorageType"],
}
self.data[:servers][db_name] = data