Skip to content

Instantly share code, notes, and snippets.

@niqdev
Forked from nathabonfim59/README.md
Created September 22, 2022 08:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save niqdev/e1c4f5d187568af08683385c5cc930b8 to your computer and use it in GitHub Desktop.
Save niqdev/e1c4f5d187568af08683385c5cc930b8 to your computer and use it in GitHub Desktop.

How to fix the "Failed to close file descriptor for child process (Operation not permitted)" in your docker ci build

Disclaimer

First off, I'm not a docker expert by any means. I just wanted my CI pipeline to work and went down the habbit hole. The solution I present can cause some security implications, be aware.

Cause

The problem is caused by a seccomp policy and a glibc >= 2.34 update that returns an EPERM (operation not permitted) insted of ENOSYS (function not implemented).

Solution/Workaround

Run your container with --security-opt seccomp=unconfined.

Example from Docker:

docker run --rm -it --security-opt seccomp=unconfined debian:jessie

Further reading

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment