Add sudo to user with docker Add user to file /etc/group (line contain sudo) Add line your_username ALL=(ALL) NOPASSWD: ALL to file /etc/sudoers Remove password (if hashed) in file /etc/shadow