controllers

package
v0.0.0-...-26fb352 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 13, 2018 License: Apache-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

View Source
const ServiceMaxTimeoutSecond = 300

ServiceMaxTimeoutSecond - Service stop | restart max timeout

Variables

This section is empty.

Functions

func Init

func Init()

Init - init basic info

Types

type ContainerController

type ContainerController struct {
	// contains filtered or unexported fields
}

ContainerController - handle http request for container

func (*ContainerController) CreateContainer

func (ctCtrl *ContainerController) CreateContainer()

CreateContainer - create container

func (*ContainerController) DeleteContainer

func (ctCtrl *ContainerController) DeleteContainer()

DeleteContainer - delete container

func (*ContainerController) Error

func (base *ContainerController) Error(status int, msg ...interface{})

Error - Unified processing error

func (*ContainerController) GetAllContainerStats

func (ctCtrl *ContainerController) GetAllContainerStats()

GetAllContainerStats - get all container's stats, include (cpu/memory/network...)

func (*ContainerController) GetContainer

func (ctCtrl *ContainerController) GetContainer()

GetContainer - get container info with name or id

func (*ContainerController) GetContainerLogs

func (ctCtrl *ContainerController) GetContainerLogs()

GetContainerLogs - get container

func (*ContainerController) GetContainerStats

func (ctCtrl *ContainerController) GetContainerStats()

GetContainerStats - get container's stats, include (cpu/memory/network...)

func (*ContainerController) GetContainerStatus

func (ctCtrl *ContainerController) GetContainerStatus()

GetContainerStatus - get container's status (running, paused, restarting, killed, dead, pid, exitcode...)

func (*ContainerController) GetContainers

func (ctCtrl *ContainerController) GetContainers()

GetContainers - get containers

func (*ContainerController) JSON

func (base *ContainerController) JSON(data interface{})

Json - Return json data

func (*ContainerController) OperateContainer

func (ctCtrl *ContainerController) OperateContainer()

OperateContainer - start/stop/restart...

func (*ContainerController) Prepare

func (ctCtrl *ContainerController) Prepare()

Prepare - format path before exec real action

func (*ContainerController) Stream

func (base *ContainerController) Stream(data string)

Stream - Format stream data to json and return

type FaqController

type FaqController struct {
	// contains filtered or unexported fields
}

FaqController - faq info

func (*FaqController) Error

func (base *FaqController) Error(status int, msg ...interface{})

Error - Unified processing error

func (*FaqController) Get

func (faq *FaqController) Get()

Get - Return config info

func (*FaqController) JSON

func (base *FaqController) JSON(data interface{})

Json - Return json data

func (*FaqController) Prepare

func (faq *FaqController) Prepare()

Prepare - Override baseController

func (*FaqController) Stream

func (base *FaqController) Stream(data string)

Stream - Format stream data to json and return

type ImageController

type ImageController struct {
	// contains filtered or unexported fields
}

ImageController - handle http request for image

func (*ImageController) DeleteImage

func (imgCtrl *ImageController) DeleteImage()

DeleteImage - delete image by id or name

func (*ImageController) Error

func (base *ImageController) Error(status int, msg ...interface{})

Error - Unified processing error

func (*ImageController) GetImage

func (imgCtrl *ImageController) GetImage()

GetImage - get image detail with image id or name

func (*ImageController) GetImages

func (imgCtrl *ImageController) GetImages()

GetImages - get images in this host

func (*ImageController) JSON

func (base *ImageController) JSON(data interface{})

Json - Return json data

func (*ImageController) Prepare

func (imgCtrl *ImageController) Prepare()

Prepare - Format path before exec real action

func (*ImageController) PullImage

func (imgCtrl *ImageController) PullImage()

PullImage - pull image from respo

func (*ImageController) Stream

func (base *ImageController) Stream(data string)

Stream - Format stream data to json and return

type InfoController

type InfoController struct {
	// contains filtered or unexported fields
}

func (*InfoController) Error

func (base *InfoController) Error(status int, msg ...interface{})

Error - Unified processing error

func (*InfoController) Get

func (info *InfoController) Get()

Get - Return docker info

func (*InfoController) JSON

func (base *InfoController) JSON(data interface{})

Json - Return json data

func (*InfoController) Prepare

func (info *InfoController) Prepare()

Prepare - Override baseController

func (*InfoController) Stream

func (base *InfoController) Stream(data string)

Stream - Format stream data to json and return

type ProjectPair

type ProjectPair struct {
	Name       string
	Containers project.InfoSet
}

ProjectPair - project service containers

type ServiceController

type ServiceController struct {
	ComposeStorage *models.ComposeStorage
	// contains filtered or unexported fields
}

ServiceController - handle http request for compose service

func (*ServiceController) CreateService

func (controller *ServiceController) CreateService()

func (*ServiceController) DeleteService

func (controller *ServiceController) DeleteService()

func (*ServiceController) Error

func (base *ServiceController) Error(status int, msg ...interface{})

Error - Unified processing error

func (*ServiceController) GetService

func (controller *ServiceController) GetService()

func (*ServiceController) GetServices

func (controller *ServiceController) GetServices()

func (*ServiceController) JSON

func (base *ServiceController) JSON(data interface{})

Json - Return json data

func (*ServiceController) OperateService

func (controller *ServiceController) OperateService()

func (*ServiceController) PackageUploadService

func (controller *ServiceController) PackageUploadService()

func (*ServiceController) Prepare

func (base *ServiceController) Prepare()

Prepare - Format path before exec real action

func (*ServiceController) Stream

func (base *ServiceController) Stream(data string)

Stream - Format stream data to json and return

type VersionController

type VersionController struct {
	// contains filtered or unexported fields
}

func (*VersionController) Error

func (base *VersionController) Error(status int, msg ...interface{})

Error - Unified processing error

func (*VersionController) Get

func (versionCtrl *VersionController) Get()

Get - Return docker version

func (*VersionController) JSON

func (base *VersionController) JSON(data interface{})

Json - Return json data

func (*VersionController) Prepare

func (versionCtrl *VersionController) Prepare()

Prepare - Override baseController

func (*VersionController) Stream

func (base *VersionController) Stream(data string)

Stream - Format stream data to json and return

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL