
Ignore-this: db98129503e90462aa3b10084d2b1f31 Salut, Pour mettre cranspasswords sur vert, j'avais besoin d'autoriser une commande sudo. Comme je ne vois pas l'intérêt de mettre cette config dans bcfg2, j'ai préféré mettre un fichier sudoers local. darcs-hash:20120602152949-28565-ba1af164a8cfd6e90983d770d47f97dedc05cabc.gz
68 lines
2.3 KiB
Python
68 lines
2.3 KiB
Python
# -*- coding: utf-8; mode: python -*-
|
|
|
|
info["perms"] = 0440
|
|
|
|
header("Configuration du sudo")
|
|
|
|
if has("users"):
|
|
@Defaults:ALL tty_tickets
|
|
|
|
@Defaults env_keep += "DARCS_EMAIL"
|
|
|
|
@# Host alias specification
|
|
|
|
@# User alias specification
|
|
@User_Alias NOUNOUS= %adm
|
|
if has("users"):
|
|
@User_Alias RESPBATS= %respbats
|
|
@User_Alias MODEROS= %moderateurs
|
|
@User_Alias IMPRIMEURS= %imprimeurs
|
|
@User_Alias BUREAU= %bureau
|
|
@Runas_Alias USERS= %users
|
|
|
|
elif has("2B"):
|
|
@User_Alias RESPBATS= %respbats
|
|
|
|
@# Cmnd alias specification
|
|
|
|
@# User privilege specification
|
|
@root ALL=(ALL) ALL
|
|
@NOUNOUS ALL=(ALL) ALL
|
|
|
|
if has("2B"):
|
|
@RESPBATS ALL=(respbats) NOPASSWD: /usr/scripts/gestion/tools/who2b.py
|
|
|
|
if has("users"):
|
|
@# Les modérateurs ont le whos
|
|
@MODEROS ALL=(respbats) /usr/scripts/gestion/whos.py
|
|
|
|
@# Câbleurs
|
|
@RESPBATS ALL=(respbats) /usr/scripts/gestion/gest_crans.py,/usr/scripts/gestion/chgpass.py
|
|
@RESPBATS ALL=(respbats) /usr/scripts/admin/mail_invalide/mail_invalide.py, /usr/scripts/admin/controle_tresorier.py, /usr/scripts/admin/controle_tresorier2.py, /usr/scripts/admin/controle_tresorier3.py
|
|
@RESPBATS ALL=(respbats) NOPASSWD: /usr/scripts/gestion/whos.py,/usr/scripts/utils/chambre.py,/usr/scripts/stats_cableurs.py,/usr/scripts/gestion/tools/whokfet.py
|
|
@RESPBATS ALL=(respbats) /usr/scripts/gestion/ressuscite.py
|
|
|
|
@# Bureau
|
|
@BUREAU ALL=(respbats) /usr/scripts/admin/controle_charte_MA.py, /usr/scripts/admin/menage_cableurs.py
|
|
|
|
@# intranet
|
|
@respbats ALL=(USERS) NOPASSWD: /usr/scripts/gestion/config_mail.py
|
|
@respbats ALL=(root) NOPASSWD: /usr/local/bin/quota
|
|
|
|
@# Génération de codes impression pour les imprimeurs
|
|
@IMPRIMEURS ALL=(root) /usr/scripts/impression/gen_code.py
|
|
|
|
@# Redémarrage de l'intranet pour les imprimeurs
|
|
@IMPRIMEURS ALL=(root) /usr/scripts/impression/redemarre_intranet.sh
|
|
|
|
@# Un chsh pour tout le monde
|
|
@ALL ALL=(respbats) /usr/scripts/gestion/chsh.py, NOPASSWD:/usr/local/bin/ldap_whoami
|
|
@# Quotas
|
|
@ALL ALL=NOPASSWD:/usr/local/bin/quota.sh
|
|
|
|
if has('arpwatch'):
|
|
@# arpwatch
|
|
@arpwatch ALL=(arpwatch) NOPASSWD:/usr/scripts/surveillance/arpwatch_sendmail.py
|
|
|
|
# Inclusion de fichier locaux
|
|
@#includedir /etc/sudoers.d
|