astefanutti / kubebox

⎈❏ Terminal and Web console for Kubernetes
http://astefanutti.github.io/kubebox
MIT License
2.14k stars 142 forks source link

Logs not updated #108

Closed lduparc closed 3 years ago

lduparc commented 3 years ago

Using echo -e "something\r" logs are not shown Same using curl --progress-bar loga appear once download is done and are not updated

Thanks

astefanutti commented 3 years ago

Do you mean you have a container that runs echo -e "something\r"? Would you have an example of a Deployment or a Pod so that we can reproduce?

lduparc commented 3 years ago

Hi,

Easy to reproduce, I'm on mac os X Catalina with a running KUbernetes based on docker-desktop. Deploy a container (java, busybox, bash...others) and set command to do an infinite loop doing echo -e "something\r".

Or run a curl command like this one curl --progress-bar "https://....." nothing shown until the end of curl.

I don't know if this related to kubebox itself.

Thanks,

astefanutti commented 3 years ago

Thanks, I've been able to reproduce with:

apiVersion: v1
kind: Pod
metadata:
  name: busybox
  labels:
    app: busybox
spec:
  containers:
    - image: busybox
      command: ["/bin/sh"]
      args: ["-c", "x=1; while true; do echo -e \"test $((x++))\r\"; sleep 1; done"]
      imagePullPolicy: IfNotPresent
      name: busybox
  restartPolicy: Always
lduparc commented 3 years ago

Hi, Thanks for info. When do you think PR will be merged ?

astefanutti commented 3 years ago

I'm working on it a bit, also adding support for copying logs into the clipboard. Hopefully I'll be done soon and I'll cut a new release right after.

astefanutti commented 3 years ago

I've just merged PR #110. I'm working on the clipboard integration and I'll cut a release soon.

lduparc commented 3 years ago

How to download and test a kubebox version in progress instead of waiting for a release ? I'm using kubebox all day long and I can report or give feedback on current version in development if this can help you.

astefanutti commented 3 years ago

You can checkout the master branch locally then run:

$ npm i
$ node index.js

That requires Node. Otherwise, the Docker image is published on every commit, so you can test the latest changes with:

$ docker run -it --rm -v ~/.kube/:/home/node/.kube/:ro astefanutti/kubebox

Let me know if that works for you.

lduparc commented 3 years ago

it works thanks