uralm1

Results 22 comments of uralm1

Old which version prints 'no cmd in ...' message to stderr, so proposed fix is: Rex::Interface::Exec::Base.pm ``` --- Base.pm.orig 2021-12-30 10:06:17.479354544 +0500 +++ Base.pm 2021-12-30 10:06:55.644286280 +0500 @@ -68,7 +68,7...

also `which` command is deprecated now: https://www.mail-archive.com/[email protected]/msg1814961.html

I found this spam output issue takes place only when CMDB is used. Moreover, Rexfile should use modules=packages. I created bash script that build docker image and demonstrates this issue:...

About `which` deprecation: I forget that recommended `command -v` is bash builtin. Reimplementing `which` in perl is a variant for future.

> Moreover, Rexfile should use modules=packages. > I don't understand that part. Could you elaborate more, please? All are tested with `rex -dT`. This Rexfile does NOT print `which` errors...

Hmm, yes, with probably broken stderr reader we can face with different variants of this bug...

That's it! My resume: `cmdb()` -> `get_operating_system()` -> `can_run()` -> `which` stderr output doesn't work properly when called from early `eval { Rexfile }` having stderr hijacked. > Currently I'm...

Yes I'm going to create some prototypes, but not so fast... offtopic: I used Capture::Tiny in the past tried to create web interface to run Rex tasks. Ended installing [Rundeck](www.rundeck.com),...

@ferki look at compile2.pl ! https://gist.github.com/uralm1/7a605925ca27b98848b43c232251aede Can we use `$SIG{__WARN__}` technic? What about compatibility? compile1.pl is a prototype of the original method.