#########################################
#
# Fichier de configuration de SAMBA
#
# Definition du Template pour Scribe-2.2
#
# Eole Dijon
#
# revu le 10/12/2009 pour Samba-3.4
#
#########################################

# Global parameters
[global]
        # configuration du serveur
        netbios name = scribe
        workgroup = domcd
        server string = Serveur Scribe
        # journalisation
        log file = /var/log/samba/%m.log
        log level = 10
        max log size = 50
        wins support = yes
        dns proxy = no
        # exploration
        preferred master = yes
        domain master = yes
        os level = 99
        admin users = @DomainAdmins
        # authentification des clients
        security = user
        # mots de passe
        encrypt passwords = yes
        lanman auth = yes
        # impression
        printing = cups
        printcap name = cups
        load printers = yes
        show add printer wizard = yes
        # synchronisation temporelle
        time server = yes
        # divers
        deadtime = 15
        domain logons = yes
        logon home = \%L%U\perso
        logon path =
        logon script = %U%a.bat
        socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
        unix extensions = no
	wide links = yes
        # smbldap-tools
        add machine script = /usr/sbin/smbldap-useradd -w -d /dev/null -s /bin/false %u
        add user to group script = /usr/sbin/smbldap-groupmod -m "%u" "%g"
        delete user from group script = /usr/sbin/smbldap-groupmod -x "%u" "%g"
        set primary group script = /usr/sbin/smbldap-usermod -g "%g" "%u"
        rename user script = /usr/sbin/smbldap-usermod -r "%unew" "%uold"
        ldap passwd sync = yes
        passdb backend = ldapsam:ldap://127.0.0.1:389
        ldap suffix = o=gouv,c=fr
        ldap admin dn = cn=admin,o=gouv,c=fr
        ldap ssl = no
        hide files = /desktop.ini/
        oplocks = no
        level2 oplocks = no
        name resolve order = wins hosts bcast lmhosts
        vfs objects = scannedonly
        scannedonly:allow_nonscanned_files=True
        # Support du mode guest
        guest ok = yes
        guest account = nobody
        map to guest = Bad User


[homes]
        comment = Home Directories
        read only = no
        browseable = no
        invalid users = nobody guest
        inherit permissions = yes
        inherit acls = yes
        create mask = 0664
        directory mask = 0775
        valid users = %U
        write list = %U
        guest ok = no

[perso]
        path = %H/perso
        comment = disque personnel pour 98 et 95
        read only = no
        browseable = no
        invalid users = nobody guest
        inherit permissions = yes
        inherit acls = yes
        create mask = 0664
        directory mask = 0775
        valid users = %U
        write list = %U
        guest ok = no

[netlogon]
        comment = Network Logon Service
        path = /home/netlogon
        browseable = no
        guest ok = yes
        read only = yes
        valid users = %U
        write list = %U
        create mask = 0644
        directory mask = 0755
        root preexec = python /usr/share/eole/backend/dyn_logon.py --user="%U" --os="%a" --machine="%m" --ip="%I"
        root postexec = rm -f /home/netlogon/%U%a.bat
        profile acls = yes

[profiles]
        path = %H/profiles
        #write list = @sambaSAMAccount
        #force group = @sambaSAMAccount
        guest ok = no
        nt acl support = no
        browseable = no

[esu]
        comment = Esu
        path = /home/esu
        browseable = no
        guest ok = yes
        read only = no
        create mask = 0644
        directory mask = 0755

[eclairng]
        comment = FTP directories
        read only = no
        browseable = no
        invalid users = nobody guest
        inherit permissions = yes
        inherit acls = yes
        create mask = 0664
        directory mask = 0775
        valid users = %U
        write list = %U
        path = %H/.ftp
        guest ok = no

[archives]
        inherit permissions = yes
        inherit acls = yes
        path=/home/alias/archives
        browseable = no
        read only = no
        guest ok = no

[printers]
        comment = All Printers
        path = /var/spool/samba
        print command = lpr-cups -P %p -o raw %s -r # Utilise le Driver de la station
        printable = yes
        browseable = yes
        available = yes
        guest ok =  no

[print$]
        path = /var/lib/samba/printers
        browseable = yes
        read only = yes
        guest ok = no
        valid users = @PrintOperators
        write list = @PrintOperators
        create mask = 0664
        directory mask = 0775
        force group = PrintOperators

#
#        Debut des partages specifiques
#

[professeurs]
	inherit permissions = no
	inherit acls = yes
	read only = no
	preserve case = yes
	create mask = 644
	directory mask = 755
	Write list = @professeurs
	Valid Users = @professeurs @DomainAdmins
	guest ok = no
	path = /home/workgroups/professeurs
	comment = professeurs
	Volume = professeurs

[icones$]
        path=/home/netlogon/icones
        browseable = No
        guest ok = Yes
        read only = no

[groupes]
        inherit permissions = yes
        inherit acls = yes
        browseable = Yes
        path = %H/groupes
        comment = disque groupes
        read only = No
        invalid users = nobody guest
        create mask = 0664
        directory mask = 0775
        valid users = %U
        write list = %U

[commun]
        inherit permissions = yes
        inherit acls = yes
        path=/home/workgroups/commun
        browseable = Yes
        guest ok = Yes
        read only = no

[devoirs]
        path = %H/devoirs
        comment = partage devoirs
        read only = no
        browseable = no
        invalid users = nobody guest
        inherit permissions = yes
        inherit acls = yes
        create mask = 0664
        directory mask = 0775
        valid users = %U
        write list = %U


