mirror of
https://github.com/open-policy-agent/opa.git
synced 2026-08-12 19:32:48 -06:00
1ad567bf00
Currently if OPA listens on a Unix socket, the socket file is created with 755 permissions. So if OPA is deployed on k8s for example and the socket path is shared via a volume between pods, due to the default permissions, the socket will not be reachable for the caller. One way around this is to match the user id for the OPA and caller containers but that is not always possible. This change adds a new flag to the OPA runtime that allows to configure the permission of the socket file. In the k8s scenario, if the file permission is updated to 777 for instance, the caller will be able to connect to OPA via the socket. Signed-off-by: Ashutosh Narkar <anarkar4387@gmail.com>