I have a Microsoft Windows domain and I want to add the ubuntu machines with Likewise-Open. There is no problem with that, but in my windows machines I have a GPO that mount a net share depending of the OU of the user that makes login into machine.
I want to have the same with the ubuntu machines and I think that maybe it can be done with pam_mount.conf.xml file
I have this configuration:
<pam_mount>
<volume fstype="cifs" server="XXX.XXX.XXX.XXX" path="Service" mountpoint="/home/likewise-open/DOMAIN/%(USER)/Service" options="nodev,nosuid" />
</pam_mount>
But I want to mount the share depending of the OU of the user. In example, if a user logs in machine1 and he belows to OU=marketing:
dn: uid=user1,ou=marketing,dc=example,dc=com
He must have a pam_mount.conf.xml file like this:
<pam_mount>
<volume fstype="cifs" server="XXX.XXX.XXX.XXX" path="marketing" mountpoint="/home/likewise-open/DOMAIN/%(USER)/marketing" options="nodev,nosuid" />
</pam_mount>
Maybe there is another better form to do this? Or it's not possible?
Thanks