Run the Container as a Non-Root User
Labs have no container engine, so nothing is built or started: your files are checked by reading them, the way a reviewer or a CI linter would. docker-compose config (to validate Compose files) and hadolint (a Dockerfile linter) are installed.
A security scan flagged the image of /home/student/projects/mailer: the Python app runs as root.
Change the Dockerfile so that:
app (and group app) with UID 10001/app and everything copied into it belong to that userUSER before the start command is app or 10001hadolint no longer reports DL3002 (last user should not be root)About this machine
Ubuntu 24.04 with no internet access. You are student with passwordless sudo. The grader checks the final state of the machine, not the commands you typed. Values like names and ports are generated for you.
Your machine is ready to start
Create a free account to open a machine and get graded.