kuttl
kuttl copied to clipboard
Run a command in a container (parse it's output)
Feedback from #164 https://github.com/kudobuilder/kuttl/issues/164#issuecomment-580707858
Run a command in a container of a pod, parse its output to determine a certain condition
Just came across this again while trying to convert more tests to use kuttl
in https://github.com/mesosphere/kudo-cassandra-operator. This feature is a prerequisite for this as many tests need to assert that a change of parameters of a KUDO operator changed the internal configuration of the deployed operator. This configuration isn't surfaced through Kubernetes objects. Instead, it can be retrieved by accessing an endpoint. This can be done using curl
, but the command output then needs to be parsed to assert the desired configuration.
Commands don't necessarily need to run in a container, they could also run in the test environment, like a regular TestStep
command does. This would suffice for the user story above.
IT is expected that kep 7 https://github.com/kudobuilder/kuttl/pull/245 will provide a solution for this... it is envisioned that this common task could be made easier with a solution for this issue... however kep 7 will make it possible. Pushing back on backlog.