Documentation ¶
Index ¶
- Constants
- Variables
- func Build(cfg *Config, cli ContainerClient) error
- func ParseNetstat(r io.Reader, cb func(*Connection)) (err error)
- type Builder
- type Compressor
- type Config
- type ConnGroup
- type Connection
- type Container
- func (c *Container) AddConnection(conn *Connection)
- func (c *Container) AddMany(conns []*Connection)
- func (c *Container) ConnectionsCount() (rv int)
- func (c *Container) IterListeners(it func(*Connection))
- func (c *Container) IterOutbounds(it func(*Connection))
- func (c *Container) SortConnections()
- func (c *Container) ToNode() (rv *node.Node)
- type ContainerClient
- type ContainerInfo
- type Enricher
- type Loader
- type MetaLoader
- type NamedBuilderWriter
- type NamedWriter
- type NetProto
- type VolumeInfo
Constants ¶
View Source
const ( ProcessRemote = "[remote]" ProcessUnknown = "[unknown]" )
Variables ¶
View Source
var ErrNotEnough = errors.New("not enough items")
Functions ¶
func Build ¶
func Build( cfg *Config, cli ContainerClient, ) error
func ParseNetstat ¶
func ParseNetstat(r io.Reader, cb func(*Connection)) (err error)
Types ¶
type Compressor ¶ added in v1.10.0
type Compressor struct {
// contains filtered or unexported fields
}
func NewCompressor ¶ added in v1.10.0
func NewCompressor( bldr NamedBuilderWriter, diff int, force bool, ) *Compressor
func (*Compressor) AddEdge ¶ added in v1.10.0
func (c *Compressor) AddEdge(e *node.Edge)
func (*Compressor) Name ¶ added in v1.10.0
func (c *Compressor) Name() string
type Config ¶ added in v1.4.0
type Config struct { Builder Builder Meta Enricher Follow set.Unordered[string] SkipEnv []string Proto NetProto OnlyLocal bool FullInfo bool NoLoops bool Deep bool }
func (*Config) MatchProto ¶ added in v1.4.0
type ConnGroup ¶ added in v1.9.0
type ConnGroup struct {
// contains filtered or unexported fields
}
func (*ConnGroup) AddListener ¶ added in v1.9.0
func (cg *ConnGroup) AddListener(c *Connection)
func (*ConnGroup) AddOutbound ¶ added in v1.9.0
func (cg *ConnGroup) AddOutbound(c *Connection)
func (*ConnGroup) IterListeners ¶ added in v1.9.0
func (cg *ConnGroup) IterListeners(it func(*Connection))
func (*ConnGroup) IterOutbounds ¶ added in v1.9.0
func (cg *ConnGroup) IterOutbounds(it func(*Connection))
type Connection ¶
type Connection struct { Process string LocalIP net.IP RemoteIP net.IP RemotePort uint16 LocalPort uint16 Proto NetProto }
func (*Connection) IsInbound ¶
func (c *Connection) IsInbound() bool
func (*Connection) IsListener ¶
func (c *Connection) IsListener() bool
func (*Connection) IsLocal ¶ added in v1.10.0
func (c *Connection) IsLocal() bool
func (*Connection) UniqID ¶ added in v1.9.0
func (c *Connection) UniqID() (id uint64, ok bool)
type Container ¶
type Container struct { Endpoints map[string]string Labels map[string]string ID string Name string Image string Info *ContainerInfo Volumes []*VolumeInfo // contains filtered or unexported fields }
func (*Container) AddConnection ¶ added in v1.9.0
func (c *Container) AddConnection(conn *Connection)
func (*Container) AddMany ¶ added in v1.9.0
func (c *Container) AddMany(conns []*Connection)
func (*Container) ConnectionsCount ¶ added in v1.4.7
func (*Container) IterListeners ¶ added in v1.5.1
func (c *Container) IterListeners(it func(*Connection))
func (*Container) IterOutbounds ¶ added in v1.5.1
func (c *Container) IterOutbounds(it func(*Connection))
func (*Container) SortConnections ¶ added in v1.9.0
func (c *Container) SortConnections()
type ContainerClient ¶
type ContainerInfo ¶ added in v1.9.0
type MetaLoader ¶ added in v1.4.0
type MetaLoader struct {
// contains filtered or unexported fields
}
func NewMetaLoader ¶ added in v1.4.0
func NewMetaLoader() *MetaLoader
func (*MetaLoader) Enrich ¶ added in v1.4.0
func (ex *MetaLoader) Enrich(n *node.Node)
func (*MetaLoader) FromReader ¶ added in v1.4.0
func (ex *MetaLoader) FromReader(r io.Reader) error
type NamedBuilderWriter ¶ added in v1.6.0
type NamedBuilderWriter interface { Builder NamedWriter }
type NamedWriter ¶ added in v1.6.0
type VolumeInfo ¶ added in v1.5.0
Click to show internal directories.
Click to hide internal directories.