~alpine/users

1

[alpine-user] Executing shell command produces nothing on Alpine linux

Details
Message ID
<CAE8G+yRxZst3oHof-u1LT+aR9KJHBtO1MAJRdWO2BVHNqKJ85A@mail.gmail.com>
Sender timestamp
1496181643
DKIM signature
missing
Download raw message
I am running shell commands inside my Perl script, but it does not work as
expected. I am in a container with Alpine Linux as my base image.

my Perl version v5.24.0.

perl -e 'my $TEST = `ls -al`; print $TEST'

This prints nothing, but works on another system where I have Perl v5.6.1
on Red Hat Linux.
Jean-Louis Fuchs <ganwell@fangorn.ch>
Details
Message ID
<20170531131038.GA5476@angua.1042.ch>
In-Reply-To
<CAE8G+yRxZst3oHof-u1LT+aR9KJHBtO1MAJRdWO2BVHNqKJ85A@mail.gmail.com> (view parent)
Sender timestamp
1496236238
DKIM signature
missing
Download raw message
Hi

On Tue, May 30, 2017 at 03:00:43PM -0700, Prashanth wrote:
> I am running shell commands inside my Perl script, but it does not work as
> expected. I am in a container with Alpine Linux as my base image.
> 
> my Perl version v5.24.0.
> 
> perl -e 'my $TEST = `ls -al`; print $TEST'
> 
> This prints nothing, but works on another system where I have Perl v5.6.1
> on Red Hat Linux.

I had this problem. Some versions of Red Hat have some special kernel (I
didn't investigate what it is). This causes many other distros not to
run on Red Hat Kernel and vice versa. I solved that by running the
container in a vagrant box.

Best,
    Jean-Louis
Reply to thread Export thread (mbox)