Skip to content

Commit

Permalink
fixing cops
Browse files Browse the repository at this point in the history
  • Loading branch information
Sean OMeara committed Dec 21, 2013
1 parent 122214a commit c510feb
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion attributes/server_rhel.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
default['mysql']['server']['packages'] = ['mysql-server']
default['mysql']['server']['slow_query_log'] = 1
default['mysql']['server']['slow_query_log_file'] = '/var/log/mysql/slow.log'
end
end

# Platformisms.. filesystem locations and such.
default['mysql']['server']['basedir'] = '/usr'
Expand Down
6 changes: 3 additions & 3 deletions recipes/_server_windows.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
template 'my.ini' do
path "#{node['mysql']['windows']['bin_dir']}\\my.ini"
source 'my.ini.erb'
notifies :restart, "service[mysql]"
notifies :restart, 'service[mysql]'
end

execute 'install mysql service' do
Expand All @@ -40,7 +40,7 @@
action :run
# only_if %Q["#{node['mysql']['windows']['mysql_bin']}" -u root -e 'show databases;'] # unreliable due to CHEF-4783; always returns 0 when run in Chef
not_if { node['mysql']['root_password_set'] }
notifies :run, "ruby_block[root-password-set]", :immediately
notifies :run, 'ruby_block[root-password-set]', :immediately
end

ruby_block 'root-password-set' do
Expand All @@ -55,7 +55,7 @@
template grants_path do
source 'grants.sql.erb'
action :create
notifies :run, "execute[mysql-install-privileges]", :immediately
notifies :run, 'execute[mysql-install-privileges]', :immediately
end

execute 'mysql-install-privileges' do
Expand Down
2 changes: 1 addition & 1 deletion test/cookbooks/mysql_test/recipes/server.rb
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,6 @@
not_if "echo 'SELECT count(name) FROM tv_chef' | mysql #{mysql_conn_args} --skip-column-names #{node['mysql_test']['database']} | grep '^3$'"
end

user "unprivileged" do
user 'unprivileged' do
action :create
end
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
end
end


describe command("su -s /bin/sh -c \"mysql --protocol socket -uroot -pilikerandompasswords -e 'show databases;'\" unprivileged") do
it { should return_exit_status 0 }
end

0 comments on commit c510feb

Please sign in to comment.