Merge pull request #760 from b8rky/support-oci-containers

install: support OCI containers as root
This commit is contained in:
Mike McQuaid
2023-04-03 08:46:52 +01:00
committed by GitHub

View File

@@ -304,6 +304,7 @@ check_run_command_as_root() {
# Allow Azure Pipelines/GitHub Actions/Docker/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
abort "Don't run this as root!"