Luca Bruno
Luca Bruno
Container lifecycle hooks are provided by kubernetes itself. Have you checked the synchronous `preStop` hook? https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/
Thanks for the PR! Code looks mostly ok. I think that test is failing because you didn't specify an absolute path for the binary. If path lookup gets too complex,...
@APTy yes, `MainPID` tells you the pid of the top-level process.
I'm not super-thrilled about it, but at the same time I would be interested in seeing this explored in a dedicated repository. In particular, I'd be interested in the maintainability...
@vaspahomov thanks for your patch. I've left a few comments in review, and it would be good to have a test for this too.
Thanks for the PR! Do you maybe have a reference to the consumer where you need this? I'm somehow inclined towards not merging this: those constants are mostly mirroring https://golang.org/pkg/log/syslog/#Priority...
Good idea, a `RebootWithContext` would fit nicely. Would you like to submit a PR with that?
@rsms thanks for the patch and the accompanying test! I've left a few comments in review, the only major one about using a `context` for timing out. The CI sometimes...
@rsms can you please rebase on latest master? CI moved to github actions in the meanwhile.
Thanks for the PR! It looks like the new test is frequently failing in CI, I think because it is internally racing (see review).