I have a Rails server running with both a web
and worker
Deployment. One starts Puma, the other Sidekiq. How can I connect to an interactive rails console
using my application's image running on my Kubernetes cluster?
Asked
Active
Viewed 2,078 times
1
mikeycgto
- 155
- 1
- 9
1 Answers
6
You should be able to to use kubectl exec -ti <container> -- bash
. From there bring up your rails console.
You might also need to add -li
for bash. That will give you a shell in the container.
It's possible to run various commands directly without the use of bash. You just need to make sure to use -ti
for the exec command so that you can interact with it.
For more details see
http://kubernetes.io/docs/user-guide/getting-into-containers/
opennomad
- 61
- 1
- 4