You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to automate running commands with docker exec. I have an example of a command that works from the command line, but can't get working in Docker.DotNet. With my container already running I opened a command line and ran: docker exec -it containerId bash -c "apt-get update". This command is successful and I can see the output from the command in the terminal window.
Instead of getting the exepected output of apt-get update, I get the error message: (OCI runtime exec failed: exec failed: unable to start container process: exec: "apt-get update": executable file not found in $PATH: unknown , ).
I believe this error may be due to trying to execute the command not in the bash shell, but haven't found any examples or docs that demonstrate how to properly execute a command in the bash shell using Docker.DotNet.
The text was updated successfully, but these errors were encountered:
I am trying to automate running commands with
docker exec
. I have an example of a command that works from the command line, but can't get working in Docker.DotNet. With my container already running I opened a command line and ran:docker exec -it containerId bash -c "apt-get update"
. This command is successful and I can see the output from the command in the terminal window.Then, I tried doing the same as:
Instead of getting the exepected output of
apt-get update
, I get the error message:(OCI runtime exec failed: exec failed: unable to start container process: exec: "apt-get update": executable file not found in $PATH: unknown , )
.I believe this error may be due to trying to execute the command not in the bash shell, but haven't found any examples or docs that demonstrate how to properly execute a command in the bash shell using Docker.DotNet.
The text was updated successfully, but these errors were encountered: