Bug 1931616 - rawhide/f34 "test -x /path/to/exe_file" does not verify correctly in fedora rawhide/34 containers on GitHub Actions
Summary: rawhide/f34 "test -x /path/to/exe_file" does not verify correctly in fedora r...
Keywords:
Status: CLOSED DUPLICATE of bug 1900021
Alias: None
Product: Fedora
Classification: Fedora
Component: bash
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Siteshwar Vashisht
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-02-22 19:39 UTC by Jun Aruga
Modified: 2021-02-23 12:04 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2021-02-23 08:36:38 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Jun Aruga 2021-02-22 19:39:23 UTC
Description of problem:

The `test -x /usr/bin/echo` in the following command returns an error exit status and executes `echo "[DEBUG] /usr/bin/echo not executable 2 by test."` in the following containers.

```
/usr/bin/test -x /usr/bin/echo || {
  echo "[DEBUG] /usr/bin/echo not executable 1 by /usr/bin/test."
}

test -x /usr/bin/echo || {
  echo "[DEBUG] /usr/bin/echo not executable 2 by test."
  false
}
```

registry.fedoraproject.org/fedora:rawhide
docker.io/fedora:rawhide
registry.fedoraproject.org/fedora:34
docker.io/fedora:34

But this does not happen on the following containers.

registry.fedoraproject.org/fedora:33
docker.io/fedora:33

I created the reproducer with GitHub Actions CI here. You see the first 2 cases succeed. But other cases fail from the GitHub Actions.
https://github.com/junaruga/fedora-test-command-test
https://github.com/junaruga/fedora-test-command-test/actions

The command `/usr/bin/test -x /usr/bin/echo` always returns success exit status.

The container is executed on the docker in the host environment Ubuntu.
I have not checked to run the container fedora:34 on podman in the host environment fedora 34 or rawhide.


Version-Release number of selected component (if applicable):
bash-5.1.4-1.fc35.x86_64
bash-5.1.0-2.fc34.x86_64

How reproducible:


Steps to Reproduce:
1. Click the top link on https://github.com/junaruga/fedora-test-command-test/actions .

You can fork https://github.com/junaruga/fedora-test-command-test and run the GitHub Actions on your forked repository to debug.

Actual results:

https://github.com/junaruga/fedora-test-command-test/runs/1955267432?check_suite_focus=true#step:6:24

```
+ /usr/bin/test -x /usr/bin/echo
+ test -x /usr/bin/echo
+ echo '[DEBUG] /usr/bin/echo not executable 2 by test.'
[DEBUG] /usr/bin/echo not executable 2 by test.
+ false
Error: Process completed with exit code 1.
```

Expected results:

```
+ test -x /usr/bin/echo
```

Additional info:
You can also check the kernel, glibc version from the log.
See https://github.com/junaruga/fedora-test-command-test/blob/main/test.sh

Thanks.

Comment 1 Kamil Dudka 2021-02-23 08:36:38 UTC
Thank you for reporting it, Jun!  This is a known issue unfortunately.  See bug #1900021 for details.

*** This bug has been marked as a duplicate of bug 1900021 ***

Comment 2 Jun Aruga 2021-02-23 12:04:31 UTC
OK! It's good to know the temporary workaround using the docker option `--security-opt seccomp=unconfined` on the issue ticket.


Note You need to log in before you can comment on or make changes to this bug.