
You might be annoyed to use docker commands with sudo. You can use docker commands without “sudo” if you follow the below procedures.
# create docker group if your enviroment does not have
sudo groupadd docker
# add current user to the docker group
sudo gpasswd -a $USER docker
# restart docker daemon
sudo systemctl restart docker
# reboot your computer.
sudo reboot -h now
For sure, there are security risks, you should consider about it.