Skip to content

Learning/non-blocking mode #169

Open

Description

@edekeijzer

Is your feature request related to a problem? Please describe.
I am using socket-proxy with the per-container labels for permissions. It's not always clear which permissions are needed by a Docker client. I now use debug logging and allow all to see what calls a certain client is using and create regexes for those accordingly.

Describe the solution you'd like
Either a general 'logging only' option for socket-proxy or a per container label, that would allow me to log warnings for each request that doesn't pass the current rules, but still allow it so it doesn't stop my client containers from working.

Describe alternatives you've considered
Some months ago I suggested this as well and @amanda-wee came with the option of enabling debug logs and scanning them. I now have a second instance of socket-proxy deployed with debug logging and assign only one or two clients to that, but there can still be quite some logs sometimes.

Activity

  1. NotaInutilis commented on Sep 24, 2026

    @NotaInutilis
    Contributor

    Yeah, that would be super useful!

    The kind of implementation I'd love for that would be having a special logging mode that writes to a file a deduplicated list of all the types of call one selected container (or several) are doing. That way we can just let them run for a day, see what happened and write the filters.

    Something like SP_LEARNINGLOG=volume/learning.log, and a label socket-proxy.learninglog=true or socket-proxy.learninglog=volume/learning.log on monitored containers.

    # CONTAINER 1
    GET /containers/{id}/changes
    POST /containers/{id}/wait
    GET /nodes
    
     # CONTAINER 2
    GET /images/search
    POST /commmit
    HEAD /_ping
    

    Maybe that big list of regexes I did can be useful to identify these and make it into more human readable results https://github.com/wollomatic/socket-proxy/wiki/Docker-API-regex-pattern-index
    (Maybe it won't but I don't want to admit it since it took a lot of time and I actually learned a lot doing it)

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions