-
-
Notifications
You must be signed in to change notification settings - Fork 218
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't run rootless with no capabilities #777
Comments
FrankenPHP (the official images) are built with that capability requirement baked in the Dockerfile. If you are on Linux, you have to give it that NET_BIND capability even if you are only using high ports. You have to fork and build a completely custom container if you want a truly rootless container. |
Maybe could we move the capacity requirement in another stage or something like that? |
I think there is something that happens when frankenphp starts. Ie. Maybe it tries to listen on the default ports which would require the capability. |
I finally fixed my problem by simply adding |
@jbonnier brilliant! |
What happened?
I'm trying to run Frankenphp in a rootless, no-capabilities, read-only container.
Everything works so far except for the no-capabilities part. I know it is required to have the NET_BIND_SERVICE capability when running as non-root to be able to map ports in the 0-1024 range. However I using ports 4443 and 8080 so I don't understand why it is not working.
Here's my
compose.yaml
file.And here's my Dockerfile :
Build Type
Docker (Debian Bookworm)
Worker Mode
No
Operating System
GNU/Linux
CPU Architecture
x86_64
PHP configuration
Relevant log output
The text was updated successfully, but these errors were encountered: