From bc65740378caef7cc58636b64278b1a912eb2e5d Mon Sep 17 00:00:00 2001 From: Boming Zhang Date: Sun, 8 Dec 2024 09:57:17 -0500 Subject: [PATCH] feat: allow tt to run any command as student with sudo --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 862b2e9..6379ba5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -11,7 +11,7 @@ RUN sed -i s@/deb.debian.org/@/mirrors.tuna.tsinghua.edu.cn/@g /etc/apt/sources. useradd -u 1000 -ms /bin/bash tt && \ useradd -u 1001 -ms /bin/bash student && \ usermod -aG student tt && \ - echo "student ALL=(tt) NOPASSWD:SETENV:/usr/local/bin/joj3\nstudent ALL=(tt) NOPASSWD:SETENV:/usr/local/bin/joj3-teapot" > /etc/sudoers.d/joj + echo "student ALL=(tt) NOPASSWD:SETENV:/usr/local/bin/joj3\ntt ALL=(student) NOPASSWD:SETENV ALL" > /etc/sudoers.d/joj # install joint-teapot # TODO: change it to FOCS gitea mirror for deployment