diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..0675a30 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,21 @@ +rs-mysql Cookbook CHANGELOG +======================= + +This file is used to list changes made in each version of the rs-mysql cookbook. + +v1.1.1 +------ + +- Update the dependency versions of `rightscale_volume` and `rightscale_backup`, supporing VMware vSphere. +- Set `rs-mysql/device/volume_type` node attribute in metadata. +- Pass `rs-mysql/device/volume_type` and `rs-mysql/device/controller_type` to `rightscale_volume`. + +v1.1.0 +------ + +- Release to coincide with the v14.0.0 Beta ServerTemplates. + +v1.0.0 +------ + +- Initial release diff --git a/attributes/volume.rb b/attributes/volume.rb index 0366d5b..07838ad 100644 --- a/attributes/volume.rb +++ b/attributes/volume.rb @@ -41,6 +41,12 @@ # I/O Operations Per Second value default['rs-mysql']['device']['iops'] = nil +# Volume type +default['rs-mysql']['device']['volume_type'] = nil + +# Controller type +default['rs-mysql']['device']['controller_type'] = nil + # The filesystem to be used on the device default['rs-mysql']['device']['filesystem'] = 'ext4' diff --git a/metadata.rb b/metadata.rb index ae2cbe7..a90843f 100644 --- a/metadata.rb +++ b/metadata.rb @@ -4,7 +4,7 @@ license 'Apache 2.0' description 'Installs and configures a MySQL server' long_description IO.read(File.join(File.dirname(__FILE__), 'README.md')) -version '1.1.0' +version '1.1.1' depends 'chef_handler', '~> 1.1.6' depends 'marker', '~> 1.0.0' @@ -14,8 +14,8 @@ depends 'rightscale_tag', '~> 1.0.2' depends 'filesystem', '~> 0.9.0' depends 'lvm', '~> 1.1.0' -depends 'rightscale_volume', '~> 1.1.0' -depends 'rightscale_backup', '~> 1.1.1' +depends 'rightscale_volume', '~> 1.2.1' +depends 'rightscale_backup', '~> 1.1.3' depends 'dns', '~> 0.1.3' depends 'git', '~> 2.7.0' @@ -127,6 +127,13 @@ :recipes => ['rs-mysql::volume', 'rs-mysql::stripe'], :required => 'optional' +attribute 'rs-mysql/device/volume_type', + :display_name => 'Volume Type', + :description => 'Volume Type to use for creating volumes. Currently this value is only used on vSphere.' + + ' Example: Platinum-Volume-Type', + :recipes => ['rs-mysql::volume', 'rs-mysql::stripe'], + :required => 'optional' + attribute 'rs-mysql/device/filesystem', :display_name => 'Device Filesystem', :description => 'The filesystem to be used on the device. Example: ext4', diff --git a/recipes/stripe.rb b/recipes/stripe.rb index dbdd634..a7ba231 100644 --- a/recipes/stripe.rb +++ b/recipes/stripe.rb @@ -45,6 +45,8 @@ # Cloud-specific volume options volume_options = {} volume_options[:iops] = node['rs-mysql']['device']['iops'] if node['rs-mysql']['device']['iops'] +volume_options[:volume_type] = node['rs-mysql']['device']['volume_type'] if node['rs-mysql']['device']['volume_type'] +volume_options[:controller_type] = node['rs-mysql']['device']['controller_type'] if node['rs-mysql']['device']['controller_type'] # Install packages required for setting up LVM include_recipe 'lvm::default' diff --git a/recipes/volume.rb b/recipes/volume.rb index a852e68..236cd62 100644 --- a/recipes/volume.rb +++ b/recipes/volume.rb @@ -34,6 +34,8 @@ # Cloud-specific volume options volume_options = {} volume_options[:iops] = node['rs-mysql']['device']['iops'] if node['rs-mysql']['device']['iops'] +volume_options[:volume_type] = node['rs-mysql']['device']['volume_type'] if node['rs-mysql']['device']['volume_type'] +volume_options[:controller_type] = node['rs-mysql']['device']['controller_type'] if node['rs-mysql']['device']['controller_type'] new_mysql_dir = "#{node['rs-mysql']['device']['mount_point']}/mysql" diff --git a/spec/backup_spec.rb b/spec/backup_spec.rb index faca509..478ae41 100644 --- a/spec/backup_spec.rb +++ b/spec/backup_spec.rb @@ -4,6 +4,7 @@ describe 'rs-mysql::backup' do let(:chef_run) do ChefSpec::Runner.new do |node| + node.set['chef_handler']['handler_path'] = '/var/chef/handlers' node.set['rs-mysql']['server_root_password'] = 'rootpass' node.set['rs-mysql']['backup']['lineage'] = 'testing' end.converge(described_recipe) diff --git a/spec/tuning_spec.rb b/spec/tuning_spec.rb index e8af28e..3eeb391 100644 --- a/spec/tuning_spec.rb +++ b/spec/tuning_spec.rb @@ -132,7 +132,7 @@ let(:tune_attributes) do described_class.tune_attributes( node.override['mysql']['tunable'], - node['memory']['total'], + category[:memory], usage ) end