Install python3-docker by entering the following commands in the terminal:
sudo apt update sudo apt install python3-docker
Description:
Python 3 wrapper to access docker.io's control socket
This package contains oodles of routines that aid in controlling docker.io over it's socket control, the same way the docker.io client controls the daemon. . This package provides Python 3 module bindings only.
Homepage: https://github.com/docker/docker-py
Version: 2.5.1-1
Section: universe/python