Docker Community Forums

Share and learn in the Docker community.

Docker exec api multiple commands

docker

(Integ) #1

i am not able to use multiple commands in the docker exec api. it allows only single command to be executed.
Any solution for this.

i need to do something like below
curl -X POST -H “Content-Type: application/json” -d ‘{“AttachStdin”: false, “AttachStdout”: true, “AttachStderr”: true, “Tty”: false,“Cmd”: [“cd /user/home && sh run.sh”]}’ http://localhost:2375/containers/id/exec