Comments (4)
Hi there,
This may be a strange request, but we'd like to use tini to control a non-daemon aware process. However, we're using a container that starts up multiple services (for legacy reasons) and controls them via daemontools.
I'm not entirely sure why you need to use TIni here. Can you perhaps clarify what you mean by "control" and "non-daemon aware"?
Currently, since tini always puts every controlled process into its own process group, this doesn't work for us.
As it turns out, older versions of Tini don't wrap their children into a process group.
I think you might want to try one of those, and let me know whether it works for you and does what you need it to do.
Specifically, you should try v0.7: https://github.com/krallin/tini/releases/tag/v0.7.0, which is the latest release before process groups were added.
Any suggestions? (happy to submit a pull request if you think it would make sense to add an option like this).
Provided the above works for you, and I can better understand what this is useful for here, I'd be happy to add or merge in a flag for this.
Thanks!
from tini.
I'm not entirely sure why you need to use TIni here. Can you perhaps clarify what you mean by "control" and "non-daemon aware"?
Yes, maybe control and non-daemon aware are the wrong terms here.
What we need is some process that will pass on signals from daemontools to its child (our process), and that collects zombies from processes that may be forked from the child. Currently our child process is an opensource piece of software that we don't want to change to put in signal handling, zombie collection etc. tini
sounded reasonably well-suited to this.
The only wrinkle was the need for tini
to be in the same process group as the child (and any of its children).
As it turns out, older versions of Tini don't wrap their children into a process group.
I think you might want to try one of those, and let me know whether it works for you and does what you need it to do.
Yes, let me take a look at v0.7
Also, let me know whether you think tini still makes sense for the use case mentioned here?
from tini.
I'm not entirely sure why you need to use TIni here. Can you perhaps clarify what you mean by "control" and "non-daemon aware"?
Yes, maybe control and non-daemon aware are the wrong terms here.
What we need is some process that will pass on signals from daemontools to its child (our process), and that collects zombies from processes that may be forked from the child. Currently our child process is an opensource piece of software that we don't want to change to put in signal handling, zombie collection etc.
tini
sounded reasonably well-suited to this.
Yes; that make sense. Just make sure you run Tini in subreaper mode (-s
), otherwise zombies won't be re-parented to it. If you don't add it, Tini should yell at you to do so anyway.
That being said, you could could also run Tini as the parent of daemontools (which may or may not require the subreaper flag depending on whether Tini is then PID 1.).
As it turns out, older versions of Tini don't wrap their children into a process group.
I think you might want to try one of those, and let me know whether it works for you and does what you need it to do.Yes, let me take a look at v0.7
👍
Also, let me know whether you think tini still makes sense for the use case mentioned here?
Yes, provided you use the subreaper flag (-s
). That being said, you might want to just run Tini at the top of your process hierarchy if that's an option.
from tini.
(I should mention that subreaper support only works on Linux >= 3.4)
from tini.
Related Issues (20)
- Supress TRACE but show DEBUG HOT 1
- Event not generated when File change happens HOT 1
- About Tini version planning? HOT 2
- aarch64 version available? HOT 3
- Non-terminal signals are killing containers running with --init flag HOT 3
- stack-protector not work HOT 4
- [FATAL tini (7)] exec bash failed: No such file or directory HOT 3
- [CVE-2023-25139]tini-static executable seems vulnerable HOT 1
- example / explanation HOT 1
- How can I confirm that tini is running? HOT 1
- prctl(PR_SET_PDEATHSIG, ...) should be called after fork(), not before HOT 4
- MI6&termux&clang-16 build failed HOT 2
- Using "docker run --init" with arguments to tini HOT 3
- tini docker windows container HOT 1
- Command-line parsing is broken if compiled with TINI_MINIMAL
- tini not running as child subreaper on AWS Lambda HOT 4
- dnf/rpm install -y tini not working HOT 1
- Latest release changed to 0.18. then switched back to 0.19 HOT 2
- Ubuntu 22.04 LTS tini install not working HOT 2
- Use Tini to ignore some signals and not pass them down.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tini.