Later versions of MariaDB still support "ALL PRIVILEGES"

This commit is contained in:
Gareth J. Greenaway 2019-02-07 11:17:07 +01:00
parent d31c902931
commit cdf52985ec
No known key found for this signature in database
GPG Key ID: 10B62F8A7CAD7A41

View File

@ -1867,7 +1867,8 @@ def grant_exists(grant,
server_version = version(**connection_args)
if 'ALL' in grant:
if salt.utils.versions.version_cmp(server_version, '8.0') >= 0:
if salt.utils.versions.version_cmp(server_version, '8.0') >= 0 and \
'MariaDB' not in server_version:
grant = ','.join([i for i in __all_privileges__])
else:
grant = 'ALL PRIVILEGES'