建议看看这个image https://hub.docker.com/repository/docker/cucker/get_command_4_run_container
Usage:
# Command alias
echo "alias get_run_command='docker run --rm -v /var/run/docker.sock:/var/run/docker.sock cucker/get_command_4_run_container'" >> ~/.bashrc
. ~/.bashrc
# Excute command
get_run_command <CONTAINER>