From 77cdaa753711897fb9147372dc9f7e4209d1baa2 Mon Sep 17 00:00:00 2001 From: "nicolas.fort" Date: Fri, 29 Mar 2024 16:00:01 +0100 Subject: [PATCH] =?UTF-8?q?Mise=20=C3=A0=20jour=20de=20'zimbra/Migration/3?= =?UTF-8?q?=5Fexports=5Ffinal.sh'?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- zimbra/Migration/3_exports_final.sh | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/zimbra/Migration/3_exports_final.sh b/zimbra/Migration/3_exports_final.sh index 2b61d3b..b374620 100644 --- a/zimbra/Migration/3_exports_final.sh +++ b/zimbra/Migration/3_exports_final.sh @@ -1,11 +1,12 @@ #!/bin/bash RCODE=$? -if [ ! whoami = "zimbra" ]; then +if [ $(id -u) -eq 0 ] +then + echo "Ce script ne doit pas être lancé en tant que root" + exit 1 + fi - echo "Le user doit être zimbra, pas root ! " - exit 1; -fi echo "Export mailboxes :" for user in `cat /opt/zimbra/nfsbackup/migration/accounts/users.txt`;