- Moved DefaultInitBinary from daemon/daemon.go to
daemon/config/config.go since it's a daemon config and is referred in
config package files.
- Added condition in GetInitPath to check for any explicitly configured
DefaultInitBinary. If not, the default value of DefaultInitBinary is
returned.
- Changed all references of DefaultInitBinary to refer to the variable
from new location.
- Added TestCommonUnixGetInitPath to test for the various values of
GetInitPath.
Fixes#32314
Signed-off-by: Sunny Gogoi <indiasuny000@gmail.com>
Invalid version strings for the init (tini)
binary were still accepted, which lead to (e.g.)
"hello world"
Being used as "vhello world"
This makes the version parsing slightly stricter
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>