summarylogtreecommitdiffstats
path: root/INSTALL
blob: 305ce0e3957490a4aa9358bbb2abda905c6a8422 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
firstline="## Installed from ws(winshare)##"
lastline="################################"
varsudo="${firstline}\n### SAMBA ###\nCmnd_Alias SAMBA = /bin/mount, /bin/umount, /sbin/mount.cifs\nALL ALL=(ALL) NOPASSWD: SAMBA\n${lastline}\n"

post_install() {
  echo -e "$varsudo" >> /etc/sudoers  
  cat << '_EOF'
  
  /etc/sudoers file was configured to allow all users to mount and unmount samba shares.

_EOF
}

post_remove() {
  sed -i "/$firstline/,/$lastline/ d" /etc/sudoers
  
  cat << '_EOF'
  
  /etc/sudoers was changed. The automatic configuration made by winshare during installation was removed.

_EOF
}

# vim:set ts=2 sw=2 et: