0

Is there a way to run commands like

service nginx start
nginx -t

when nginx is running in a docker container without having to start the container's bash shell?

Manolis
  • 167
  • 1
  • 12

1 Answers1

0

You can overwrite ENTRYPOINT or CMD by specifying them on docker run...

If you really need to start a service then add a ; sleep infinity.

CFrei
  • 3,552
  • 1
  • 15
  • 29