diff --git a/Library/Homebrew/brew.sh b/Library/Homebrew/brew.sh index 125861360a..7c59fd881e 100644 --- a/Library/Homebrew/brew.sh +++ b/Library/Homebrew/brew.sh @@ -192,8 +192,9 @@ source "${HOMEBREW_LIBRARY}/Homebrew/utils/helpers.sh" check-run-command-as-root() { [[ "${EUID}" == 0 || "${UID}" == 0 ]] || return - # Allow Azure Pipelines/GitHub Actions/Docker/Concourse/Kubernetes to do everything as root (as it's normal there) + # Allow Azure Pipelines/GitHub Actions/Docker/Podman/Concourse/Kubernetes to do everything as root (as it's normal there) [[ -f /.dockerenv ]] && return + [[ -f /run/.containerenv ]] && return [[ -f /proc/1/cgroup ]] && grep -E "azpl_job|actions_job|docker|garden|kubepods" -q /proc/1/cgroup && return # Homebrew Services may need `sudo` for system-wide daemons.