Documentation ¶
Index ¶
- type AcadockClient
- type Client
- func (c *Client) AllContainersUsage() (ContainersUsage, error)
- func (c *Client) CpuUsage(dockerId string) (*CpuUsage, error)
- func (c *Client) HostUsage(opts HostUsageOpts) (HostUsage, error)
- func (c *Client) Memory(dockerId string) (*MemoryUsage, error)
- func (c *Client) NetUsage(dockerId string) (*NetUsage, error)
- func (c *Client) Usage(dockerId string, net bool) (*Usage, error)
- type ClientOpts
- type ContainersUsage
- type CpuUsage
- type HostCpuUsage
- type HostMemoryUsage
- type HostUsage
- type HostUsageOpts
- type MemoryUsage
- type NetUsage
- type Usage
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AcadockClient ¶ added in v0.6.0
type AcadockClient interface { AllContainersUsage() (ContainersUsage, error) Memory(dockerId string) (*MemoryUsage, error) CpuUsage(dockerId string) (*CpuUsage, error) NetUsage(dockerId string) (*NetUsage, error) Usage(dockerId string, net bool) (*Usage, error) HostUsage(opts HostUsageOpts) (HostUsage, error) }
type Client ¶
func (*Client) AllContainersUsage ¶ added in v0.3.2
func (c *Client) AllContainersUsage() (ContainersUsage, error)
func (*Client) HostUsage ¶ added in v0.6.0
func (c *Client) HostUsage(opts HostUsageOpts) (HostUsage, error)
type ClientOpts ¶ added in v0.6.0
func WithAuthentication ¶ added in v0.6.0
func WithAuthentication(user, pass string) ClientOpts
type ContainersUsage ¶ added in v0.3.1
func NewContainersUsage ¶ added in v0.3.1
func NewContainersUsage() ContainersUsage
type CpuUsage ¶ added in v0.3.0
type CpuUsage struct {
UsageInPercents int `json:"usage_in_percents"`
}
type HostCpuUsage ¶ added in v0.6.0
type HostMemoryUsage ¶ added in v0.6.0
type HostMemoryUsage struct { Free uint64 `json:"free"` Total uint64 `json:"total"` Swap uint64 `json:"swap"` MemoryUsage uint64 `json:"memory_usage"` MemoryCommitted uint64 `json:"memory_committed"` MaxMemoryUsage uint64 `json:"max_memory_usage"` SwapUsage uint64 `json:"swap_usage"` SwapCommitted uint64 `json:"swap_committed"` MaxSwapUsage uint64 `json:"max_swap_usage"` }
type HostUsage ¶ added in v0.6.0
type HostUsage struct { CPU HostCpuUsage `json:"cpu"` Memory HostMemoryUsage `json:"memory"` }
type HostUsageOpts ¶ added in v0.6.0
type HostUsageOpts struct {
IncludeContainerIfLabel string
}
type MemoryUsage ¶
Click to show internal directories.
Click to hide internal directories.