mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-07-07 20:08:58 +00:00
Assure group when push system user to asset (#3155)
Some OS like SUSE12SP3 may not create group when create an OS user. In this case, the task "Set home dir permission" will always fail as the group doesn't exist in the system.
This commit is contained in:
parent
996da2d90e
commit
041bab88c0
@ -384,6 +384,15 @@ def get_push_linux_system_user_tasks(system_user):
|
|||||||
),
|
),
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
'name': 'Add group {}'.format(system_user.username),
|
||||||
|
'action': {
|
||||||
|
'module': 'group',
|
||||||
|
'args': 'name={} state=present'.format(
|
||||||
|
system_user.username,
|
||||||
|
),
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
'name': 'Check home dir exists',
|
'name': 'Check home dir exists',
|
||||||
'action': {
|
'action': {
|
||||||
|
Loading…
Reference in New Issue
Block a user