1
0
mirror of https://github.com/altlinux/gpupdate.git synced 2025-03-21 18:50:38 +03:00

Correction of final paths for catalogs in autofs_auto.j2, autofs_auto_hide.j2, cifs_applier.py

This commit is contained in:
Valery Sinelnikov 2022-12-05 13:26:29 +04:00
parent e46d717af8
commit b4e50c2ef8
3 changed files with 7 additions and 4 deletions

View File

@ -172,9 +172,11 @@ class cifs_applier_user(applier_frontend):
self.user_creds = self.auto_master_d / cred_file
if username:
self.mount_dir = Path(os.path.join(self.home, 'UserDrive'))
self.mntTarget = 'UserDrive'
else:
self.mount_dir = Path(os.path.join(self.home, 'Drive'))
self.mntTarget = 'Drive'
self.mount_dir = Path(os.path.join(self.home))
self.drives = storage_get_drives(self.storage, self.sid)
self.template_loader = jinja2.FileSystemLoader(searchpath=self.__template_path)
@ -246,6 +248,7 @@ class cifs_applier_user(applier_frontend):
autofs_settings = dict()
autofs_settings['home_dir'] = self.home
autofs_settings['mntTarget'] = self.mntTarget
autofs_settings['mount_file'] = self.user_config.resolve()
autofs_text = self.template_auto.render(**autofs_settings)

View File

@ -16,5 +16,5 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#}
{{ home_dir }}/net {{ mount_file }} -t 120 --browse
{{ home_dir }}/{{mntTarget}} {{ mount_file }} -t 120 --browse

View File

@ -16,5 +16,5 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#}
{{ home_dir }}/.net {{ mount_file }} -t 120
{{ home_dir }}/.{{mntTarget}} {{ mount_file }} -t 120