update registiration.py add module

This commit is contained in:
Agah Öz 2020-08-10 16:41:58 +03:00
parent fbee43ce5c
commit de02e60a3c
1 changed files with 1 additions and 1 deletions

View File

@ -534,6 +534,7 @@ class Registration:
self.util.execute(change_home.format(new_home_dir, new_username))
self.logger.debug("User: '{0}' will be enabled and changed username and home directory of username".format(p.pw_name))
def disable_local_users(self):
passwd_cmd = 'passwd -l {}'
change_home = 'usermod -m -d {0} {1}'
@ -557,7 +558,6 @@ class Registration:
Util.execute(change_home.format(new_home_dir, new_username))
Util.execute(change_permisson.format(new_home_dir))
def change_permissions_for_local_users(self):
add_user_conf_file = "/etc/adduser.conf"
file_dir_mode = open(add_user_conf_file, 'r')