fix: check_root incompatible with set -e when running as root
Some checks failed
Build and Push Docker Images / docker (push) Failing after 8s
Some checks failed
Build and Push Docker Images / docker (push) Failing after 8s
This commit is contained in:
@@ -55,7 +55,11 @@ while [[ $# -gt 0 ]]; do
|
||||
done
|
||||
|
||||
# ─── Vérifications communes ───────────────────────────────────────────────────
|
||||
check_root() { [[ $EUID -ne 0 ]] && error "Ce script doit être exécuté en root (sudo)."; }
|
||||
check_root() {
|
||||
if [[ $EUID -ne 0 ]]; then
|
||||
error "Ce script doit être exécuté en root (sudo)."
|
||||
fi
|
||||
}
|
||||
check_deps() {
|
||||
command -v python3 &>/dev/null || error "Python 3 est requis : apt install python3 python3-venv"
|
||||
command -v docker &>/dev/null || error "Docker est requis. Consultez https://docs.docker.com/engine/install/"
|
||||
|
||||
Reference in New Issue
Block a user