I’m trying to forward a simple command to an application that’s running in a docker container.
I can run the command successfully using docker attach container and then entering the command that I need to run. The problem is I want to do it automatically using a shell script.
I can’t figure out how to run the command using docker exec
All articles that popped up while looking for solutions were showing how to run a program or script inside the container. I’m trying to pass that command to a java application that’s running in the container.
Is it somehow possible to run a command using docker exec in an already running/active TTY?
What am I missing?
Any help would be appreciated.