diff options
| author | Aiden Grossman <aidengrossman@google.com> | 2024-12-16 21:22:34 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-12-16 13:22:34 -0800 |
| commit | b86a22aa3915c5ed7f802ebad7578c0906bdd8a9 (patch) | |
| tree | 3fa0adde025d377c406eb7c564b6bf80e81afe29 /.github/workflows/containers | |
| parent | 3769fcb3e78eba5f3e34d1c2dfa994625edb005a (diff) | |
[Github] Default to non-root user in linux CI container (#119987)
This patch sets the default user in the linux CI container to a non-root
user, which enables properly testing a couple of features, particularly
in libcxx.
Diffstat (limited to '.github/workflows/containers')
| -rw-r--r-- | .github/workflows/containers/github-action-ci/Dockerfile | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/.github/workflows/containers/github-action-ci/Dockerfile b/.github/workflows/containers/github-action-ci/Dockerfile index ee827ad8a959..58355d261c43 100644 --- a/.github/workflows/containers/github-action-ci/Dockerfile +++ b/.github/workflows/containers/github-action-ci/Dockerfile @@ -68,3 +68,10 @@ RUN apt-get update && \ ENV LLVM_SYSROOT=$LLVM_SYSROOT ENV PATH=${LLVM_SYSROOT}/bin:${PATH} + +# Create a new user to avoid test failures related to a lack of expected +# permissions issues in some tests. Set the user id to 1001 as that is the +# user id that Github Actions uses to perform the checkout action. +RUN useradd gha -u 1001 -m -s /bin/bash +USER gha + |
