Details
Description
When using WINDOWS_LOGIN, the login.sql.erb templates are incorrectly checking the sys.sql_logins table instead of sys.server_principals.
Example manifest snippet (NOTE: the '//' in the first line is actually a pair of back-slashes but Jira doesn't like that for somereason):
sqlserver::login{ "mydomain//foo": |
instance => 'MSSQLSERVER', |
login_type => 'WINDOWS_LOGIN', |
ensure => 'present', |
svrroles => { 'sysadmin' => 1, 'serveradmin' => 0, 'processadmin' => 0, 'setupadmin' => 0, 'bulkadmin' => 0, 'diskadmin' => 0, 'dbcreator' => 0, }, |
require => Sqlserver::Database['bar'], |
}
|
Unfortunately, the error is chomped by Puppet agent runs, but if you copy the generated SQL from such a config into MSSQL Studio you will find the following error on all but the first run:
The server principal 'mydomain\foo' already exists.
Attachments
Issue Links
- relates to
-
MODULES-2305 sqlserver::login disabled => 'true' doesn't work
-
- Resolved
-
-
MODULES-2323 sqlserver: Unable to delete/absent sqlserver::login
-
- Resolved
-