0

I'm writing a Python script, and would like to transparently present my call to kind cluster create (kubernetes-in-docker) in a terminal that runs this Python script.

I have been using Python's subprocess.check_output until I realized that wrapping the call like that hid a lot of output.

Is there from the Python script, to invoke kind create cluster as if I'd been calling it directly from the command line without invoking it from a python script?

If we can make Python do this, it would have to:

  1. To stream the output
  2. To get output that can updates like the animated dots
  3. To get the emoji images represented as well

kind create cluster running in a bash terminal

enter image description here

consideRatio
  • 981
  • 10
  • 18

1 Answers1

0

I learned that I simply wanted to start using subprocess.run(cmd), that gave me everything I wanted.

It allowed my ./my-python-script.py to run code within it that resulted in everything I wanted to see, such as colors, animated dots, emojis.

consideRatio
  • 981
  • 10
  • 18