Security in Docker
- Run Docker with a user other than root imperatively
docker run --user=1000 ubuntu sleep 3600
- Alternatively, we can define user ID in Dockerfile
FROM ubuntu
USER 1000
- Then run with
docker build -t my-ubuntu-image .
today i learned
tags
projects
about
docker run --user=1000 ubuntu sleep 3600
FROM ubuntu
USER 1000
docker build -t my-ubuntu-image .