Heap profile is empty inside docker container
Expected Behavior
Commands other than the doctor command work inside docker containers.
Current Behavior
I am running node clinic with a project at work. The doctor command work find and outputs files with data. If I try any other command the output files are empty. Has anyone been able to run this successfully in side docker?
Steps to Reproduce (for bugs)
Running ./node_modules/.bin/clinic ${doctorMode} -- node --max-old-space-size=4096 inside the container, where dockerMode is one of the available commands.
Sample upload
File is empty
Environment
docker-image - > node:14.18.2-alpine latest clinic version
- Node.js version: Node 14.18.2
- Browser name and version: Chrome 97
Host OS is Ubuntu x86_64 x86_64 x86_64 GNU/Linux
Try one of the approaches mentioned in https://github.com/clinicjs/node-clinic/issues/10
@RafaelGSS yes I saw that thread. The heap profile will start up, but when I kill the process the file is empty and I am not seeing any errors or logs.
I am seeing the same problem without using a docker container on Ubuntu with Node.js v14. I tried using the timeout --signal=SIGINT 20m approach. I see "Received CTRL+C, closing process..." followed by no errors. Heap profile file is created but still empty.
I am more than willing to bet you're hitting https://github.com/clinicjs/node-clinic/issues/444#issuecomment-1474997090
It is most likely similar, but I think there is also an extra problem with doing this on Windows due to the unique way it handles signals.