s2i-php-container icon indicating copy to clipboard operation
s2i-php-container copied to clipboard

Building RHEL8 7.2 RUN /usr/libexec/container-setup && rpm-file-permissions Fails

Open redstorm1 opened this issue 5 years ago • 3 comments

building s2i-php-container-master\7.2\Dockerfile.rhel8 The step RUN /usr/libexec/container-setup && rpm-file-permissions fails with access denide. have tried USER root just prior to this step same result.

020-02-11T23:23:38.0488316Z Step 11/20 : USER root 2020-02-11T23:23:38.0799226Z ---> Running in 71a0b64c4812 2020-02-11T23:23:39.0453161Z Removing intermediate container 71a0b64c4812 2020-02-11T23:23:39.0454474Z ---> ecb16ff6ae3e 2020-02-11T23:23:39.0454914Z Step 12/20 : RUN /usr/libexec/container-setup && rpm-file-permissions 2020-02-11T23:23:39.0744783Z ---> Running in 8c5c1dc02804 2020-02-11T23:23:39.3000133Z [91m/bin/sh: /usr/libexec/container-setup: Permission denied 2020-02-11T23:23:39.4626100Z [0mThe command '/bin/sh -c /usr/libexec/container-setup && rpm-file-permissions' returned a non-zero code: 126 2020-02-11T23:23:39.4739985Z ##[error]The command '/bin/sh -c /usr/libexec/container-setup && rpm-file-permissions' returned a non-zero code: 126 2020-02-11T23:23:39.4779070Z ##[error]The process '/usr/bin/docker' failed with exit code 126 2020-02-11T23:23:39.4868737Z ##[section]Finishing: buildAndPush

redstorm1 avatar Feb 11 '20 23:02 redstorm1

Same with building 7.3 rhel8

2020-02-11T23:32:34.4892173Z Step 11/19 : RUN /usr/libexec/container-setup && rpm-file-permissions 2020-02-11T23:32:34.5151776Z ---> Running in 7e84e3fe6658 2020-02-11T23:32:34.7147835Z [91m/bin/sh: /usr/libexec/container-setup: Permission denied 2020-02-11T23:32:34.8833486Z [0mThe command '/bin/sh -c /usr/libexec/container-setup && rpm-file-permissions' returned a non-zero code: 126 2020-02-11T23:32:34.8961337Z ##[error]The command '/bin/sh -c /usr/libexec/container-setup && rpm-file-permissions' returned a non-zero code: 126 2020-02-11T23:32:34.9031444Z ##[error]The process '/usr/bin/docker' failed with exit code 126 2020-02-11T23:32:34.9121458Z ##[section]Finishing: buildAndPush

redstorm1 avatar Feb 11 '20 23:02 redstorm1

FIX

Add above the problematic step.


USER root RUN chmod +x /usr/libexec/container-setup


redstorm1 avatar Feb 12 '20 01:02 redstorm1

Hi @redstorm1, thanks for opening the issue. As far as I can see libexec/container-setup already has permissions to execute, so likely the problem is caused by some configuration on your side (umask?).

pkubatrh avatar Feb 12 '20 06:02 pkubatrh