0

I ran a docker run on a docker image with a long convoluted command syntax that I have since forgotton and lost. Is there any way to derive the syntax that ran a container given the container ID?

I know docker inspect can give you information about the container but I was hoping the docker run syntax would be saved somewhere.

Frak
  • 832
  • 1
  • 11
  • 32
  • Store all the run parameters in a [docker-compose.yml](https://docs.docker.com/compose/) file and you will never have to worry about forgetting them again. – Zeitounator Dec 01 '19 at 16:58

1 Answers1

-1

As mentioned by Zeitounator, this was answered here, but just adding it here for completeness:

sudo docker run --rm -v /var/run/docker.sock:/var/run/docker.sock \
    assaflavie/runlike <Your_Container_ID>
Frak
  • 832
  • 1
  • 11
  • 32