Skip to content

Commit 80b4c23

Browse files
author
Brint O'Hearn
committed
FC023 fixes
1 parent d7ccd77 commit 80b4c23

File tree

3 files changed

+8
-10
lines changed

3 files changed

+8
-10
lines changed

Strainerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
knife: bundle exec knife cookbook test $COOKBOOK
2-
foodcritic: bundle exec foodcritic -f any $SANDBOX/$COOKBOOK --tags ~FC023 --tags ~FC037
2+
foodcritic: bundle exec foodcritic -f any $SANDBOX/$COOKBOOK
33
kitchen: bundle exec kitchen test

recipes/database.rb

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,9 @@
2020
# limitations under the License.
2121
#
2222

23-
unless platform_family?('windows')
24-
mysql_client 'default' do
25-
action :create
26-
end
23+
mysql_client 'default' do
24+
action :create
25+
not_if { node['platform_family'] == 'windows' }
2726
end
2827

2928
mysql2_chef_gem 'default' do

recipes/nginx.rb

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,8 @@
5555
# The following block is specifically for OS's like CentOS that include a
5656
# default site as a part of the install. This block will only be triggered if
5757
# node['nginx']['default_site_enable'] is set to false.
58-
if node['platform_family'] == 'rhel' && !node['nginx']['default_site_enabled']
59-
file File.join(node['nginx']['dir'], 'conf.d', 'default.conf') do
60-
action :delete
61-
notifies :reload, 'service[nginx]'
62-
end
58+
file File.join(node['nginx']['dir'], 'conf.d', 'default.conf') do
59+
action :delete
60+
notifies :reload, 'service[nginx]'
61+
only_if { node['platform_family'] == 'rhel' && !node['nginx']['default_site_enabled'] }
6362
end

0 commit comments

Comments
 (0)