# README
Docker authorization extension api.
Go handler to create external authorization extensions for Docker.
Usage
This library is designed to be integrated in your program.
- Implement the
authorization.Plugin
interface. - Initialize a
authorization.Handler
with your implementation. - Call either
ServeTCP
orServeUnix
from theauthorization.Handler
.
Example using TCP sockets:
p := MyAuthZPlugin{}
h := authorization.NewHandler(p)
h.ServeTCP("test_plugin", ":8080")
Example using Unix sockets:
p := MyAuthZPlugin{}
h := authorization.NewHandler(p)
h.ServeUnix("root", "test_plugin")
Full example plugins
License
MIT
# Functions
NewHandler initializes the request handler with a plugin implementation.
# Interfaces
Plugin represent the interface a plugin must fulfill.