Skip to content

Commit 2c93463

Browse files
authored
Merge pull request voxpupuli#908 from wyardley/shoikan_pr_890
Prevent custom fact from complaining when openresty is installed
2 parents 453887a + 15fb767 commit 2c93463

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/facter/nginx_version.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
setcode do
33
if Facter.value('kernel') != 'windows' && Facter::Util::Resolution.which('nginx')
44
nginx_version = Facter::Util::Resolution.exec('nginx -v 2>&1')
5-
%r{nginx version: nginx\/([\w\.]+)}.match(nginx_version)[1]
5+
%r{nginx version: (nginx|openresty)\/([\w\.]+)}.match(nginx_version)[2]
66
end
77
end
88
end

0 commit comments

Comments
 (0)