Answer the question
In order to leave comments, you need to log in
How to write the passed parameters to the container file when starting the container (docker)?
I create a container and pass parameters
docker run --name my-conteiner -it my-image php -r "hello world"
Answer the question
In order to leave comments, you need to log in
docker run --name my-conteiner -it my-image command_that_writes_to_file
The same php in your case will write to the container.
An elegant version with a Dockerfile, for example, is described here stackoverflow.com/questions/40238969/how-to-pass-c...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question