Sync hotfixes
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
parent
c77cd696c7
commit
2628faa9d0
|
@ -202,7 +202,8 @@ BEGIN
|
|||
JSON_OBJECT(
|
||||
'mysql_old_password', JSON_VALUE(t.`Priv`, '$.mysql_old_password'),
|
||||
'mysql_native_password', JSON_VALUE(t.`Priv`, '$.mysql_native_password'),
|
||||
'authentication_string', JSON_VALUE(t.`Priv`, '$.authentication_string')
|
||||
'authentication_string', JSON_VALUE(t.`Priv`, '$.authentication_string'),
|
||||
'ssl_type', JSON_VALUE(t.`Priv`, '$.ssl_type')
|
||||
)
|
||||
)
|
||||
FROM tRole r
|
||||
|
|
|
@ -226,7 +226,7 @@ class SyncLdap extends SyncConnector {
|
|||
// Recreate roles
|
||||
|
||||
let roles = await $.Role.find({
|
||||
fields: ['id', 'name']
|
||||
fields: ['id', 'name', 'description']
|
||||
});
|
||||
let roleRoles = await $.RoleRole.find({
|
||||
fields: ['role', 'inheritsFrom']
|
||||
|
@ -251,13 +251,12 @@ class SyncLdap extends SyncConnector {
|
|||
return {key: user.roleFk, val: user.name};
|
||||
});
|
||||
|
||||
console.log;
|
||||
|
||||
reqs = [];
|
||||
for (let role of roles) {
|
||||
let newEntry = {
|
||||
objectClass: ['top', 'posixGroup'],
|
||||
cn: role.name,
|
||||
description: role.description,
|
||||
gidNumber: accountConfig.idBase + role.id
|
||||
};
|
||||
|
||||
|
|
|
@ -28,6 +28,7 @@ class SyncSamba extends SyncConnector {
|
|||
url: `ldaps://${sambaConfig.host}:636`,
|
||||
tlsOptions: {rejectUnauthorized: false}
|
||||
});
|
||||
await adClient.bind(sambaConfig.adUser, sambaConfig.adPassword);
|
||||
|
||||
Object.assign(this, {
|
||||
sambaConfig,
|
||||
|
@ -98,8 +99,6 @@ class SyncSamba extends SyncConnector {
|
|||
adClient
|
||||
} = this;
|
||||
|
||||
await adClient.bind(sambaConfig.adUser, sambaConfig.adPassword);
|
||||
|
||||
let opts = {
|
||||
scope: 'sub',
|
||||
attributes: ['sAMAccountName'],
|
||||
|
|
Loading…
Reference in New Issue