Skip to content

Commit 66c0f6a

Browse files
authored
Merge pull request #530 from btolab/relax-version-regex
support percona mongodb version output
2 parents 7e3ba69 + 68212f8 commit 66c0f6a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/facter/mongodb_version.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
setcode do
33
if Facter::Core::Execution.which('mongo')
44
mongodb_version = Facter::Core::Execution.execute('mongo --version 2>&1')
5-
%r{^MongoDB shell version:?\s+([\w\.]+)}.match(mongodb_version)[1]
5+
%r{MongoDB shell version:?\s+v?([\w\.]+)}.match(mongodb_version)[1]
66
end
77
end
88
end

0 commit comments

Comments
 (0)