app

package
v0.0.0-...-136c4f7 Latest Latest
Warning

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

Go to latest
Published: Aug 4, 2018 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MountContainerController

func MountContainerController(service *goa.Service, ctrl ContainerController)

MountContainerController "mounts" a Container resource controller on the given service.

func MountSwaggerController

func MountSwaggerController(service *goa.Service, ctrl SwaggerController)

MountSwaggerController "mounts" a Swagger resource controller on the given service.

func MountUserController

func MountUserController(service *goa.Service, ctrl UserController)

MountUserController "mounts" a User resource controller on the given service.

func NewJWTSecurity

func NewJWTSecurity() *goa.JWTSecurity

NewJWTSecurity creates a jwt security definition.

func UseJWTMiddleware

func UseJWTMiddleware(service *goa.Service, middleware goa.Middleware)

UseJWTMiddleware mounts the jwt auth middleware onto the service.

Types

type AddAuthorizedKeysUserContext

type AddAuthorizedKeysUserContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	Payload *UserAuthorizedKey
}

AddAuthorizedKeysUserContext provides the user addAuthorizedKeys action context.

func NewAddAuthorizedKeysUserContext

func NewAddAuthorizedKeysUserContext(ctx context.Context, r *http.Request, service *goa.Service) (*AddAuthorizedKeysUserContext, error)

NewAddAuthorizedKeysUserContext parses the incoming request URL and body, performs validations and creates the context used by the user controller addAuthorizedKeys action.

func (*AddAuthorizedKeysUserContext) BadRequest

func (ctx *AddAuthorizedKeysUserContext) BadRequest() error

BadRequest sends a HTTP response with status code 400.

func (*AddAuthorizedKeysUserContext) InternalServerError

func (ctx *AddAuthorizedKeysUserContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*AddAuthorizedKeysUserContext) NoContent

func (ctx *AddAuthorizedKeysUserContext) NoContent() error

NoContent sends a HTTP response with status code 204.

type ContainerConfig

type ContainerConfig struct {
	DefaultShell *string `form:"defaultShell,omitempty" json:"defaultShell,omitempty" yaml:"defaultShell,omitempty" xml:"defaultShell,omitempty"`
}

ContainerConfig user type.

type ContainerController

ContainerController is the controller interface for the Container actions.

type CreateContainerContext

type CreateContainerContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	Command     []string
	Entrypoint  []string
	Env         []string
	Image       string
	Name        string
	SslRedirect bool
	Volumes     []string
	WorkingDir  *string
}

CreateContainerContext provides the container create action context.

func NewCreateContainerContext

func NewCreateContainerContext(ctx context.Context, r *http.Request, service *goa.Service) (*CreateContainerContext, error)

NewCreateContainerContext parses the incoming request URL and body, performs validations and creates the context used by the container controller create action.

func (*CreateContainerContext) BadRequest

func (ctx *CreateContainerContext) BadRequest(r error) error

BadRequest sends a HTTP response with status code 400.

func (*CreateContainerContext) Conflict

func (ctx *CreateContainerContext) Conflict(r error) error

Conflict sends a HTTP response with status code 409.

func (*CreateContainerContext) InternalServerError

func (ctx *CreateContainerContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*CreateContainerContext) OK

OK sends a HTTP response with status code 200.

type DownloadContainerContext

type DownloadContainerContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	ID           string
	InternalPath string
}

DownloadContainerContext provides the container download action context.

func NewDownloadContainerContext

func NewDownloadContainerContext(ctx context.Context, r *http.Request, service *goa.Service) (*DownloadContainerContext, error)

NewDownloadContainerContext parses the incoming request URL and body, performs validations and creates the context used by the container controller download action.

func (*DownloadContainerContext) InternalServerError

func (ctx *DownloadContainerContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*DownloadContainerContext) NotFound

func (ctx *DownloadContainerContext) NotFound(r error) error

NotFound sends a HTTP response with status code 404.

func (*DownloadContainerContext) OK

func (ctx *DownloadContainerContext) OK(resp []byte) error

OK sends a HTTP response with status code 200.

type ExecContainerContext

type ExecContainerContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	Command []string
	ID      string
	Tty     *bool
}

ExecContainerContext provides the container exec action context.

func NewExecContainerContext

func NewExecContainerContext(ctx context.Context, r *http.Request, service *goa.Service) (*ExecContainerContext, error)

NewExecContainerContext parses the incoming request URL and body, performs validations and creates the context used by the container controller exec action.

func (*ExecContainerContext) InternalServerError

func (ctx *ExecContainerContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*ExecContainerContext) NotFound

func (ctx *ExecContainerContext) NotFound(r error) error

NotFound sends a HTTP response with status code 404.

type GetConfigContainerContext

type GetConfigContainerContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	ID string
}

GetConfigContainerContext provides the container getConfig action context.

func NewGetConfigContainerContext

func NewGetConfigContainerContext(ctx context.Context, r *http.Request, service *goa.Service) (*GetConfigContainerContext, error)

NewGetConfigContainerContext parses the incoming request URL and body, performs validations and creates the context used by the container controller getConfig action.

func (*GetConfigContainerContext) InternalServerError

func (ctx *GetConfigContainerContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*GetConfigContainerContext) NotFound

func (ctx *GetConfigContainerContext) NotFound() error

NotFound sends a HTTP response with status code 404.

func (*GetConfigContainerContext) OK

OK sends a HTTP response with status code 200.

type GetConfigUserContext

type GetConfigUserContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
}

GetConfigUserContext provides the user getConfig action context.

func NewGetConfigUserContext

func NewGetConfigUserContext(ctx context.Context, r *http.Request, service *goa.Service) (*GetConfigUserContext, error)

NewGetConfigUserContext parses the incoming request URL and body, performs validations and creates the context used by the user controller getConfig action.

func (*GetConfigUserContext) InternalServerError

func (ctx *GetConfigUserContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*GetConfigUserContext) OK

OK sends a HTTP response with status code 200.

type GetDefaultShellUserContext

type GetDefaultShellUserContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
}

GetDefaultShellUserContext provides the user getDefaultShell action context.

func NewGetDefaultShellUserContext

func NewGetDefaultShellUserContext(ctx context.Context, r *http.Request, service *goa.Service) (*GetDefaultShellUserContext, error)

NewGetDefaultShellUserContext parses the incoming request URL and body, performs validations and creates the context used by the user controller getDefaultShell action.

func (*GetDefaultShellUserContext) InternalServerError

func (ctx *GetDefaultShellUserContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*GetDefaultShellUserContext) OK

OK sends a HTTP response with status code 200.

type GoaContainerConfig

type GoaContainerConfig struct {
	DefaultShell *string `form:"defaultShell,omitempty" json:"defaultShell,omitempty" yaml:"defaultShell,omitempty" xml:"defaultShell,omitempty"`
}

GoaContainerConfig media type (default view)

Identifier: vpn.application/goa.container.config; view=default

type GoaContainerCreateResults

type GoaContainerCreateResults struct {
	// endpoint URL
	Endpoints []string `form:"endpoints" json:"endpoints" yaml:"endpoints" xml:"endpoints"`
	// container id
	ID int `form:"id" json:"id" yaml:"id" xml:"id"`
}

The results of container creation (default view)

Identifier: vnd.application/goa.container.create.results+json; view=default

func (*GoaContainerCreateResults) Validate

func (mt *GoaContainerCreateResults) Validate() (err error)

Validate validates the GoaContainerCreateResults media type instance.

type GoaContainerDownloadResult

type GoaContainerDownloadResult struct {
	File *multipart.FileHeader `form:"file,omitempty" json:"file,omitempty" yaml:"file,omitempty" xml:"file,omitempty"`
}

GoaContainerDownloadResult media type (default view)

Identifier: vpn.application/goa.container.download.result; view=default

type GoaContainerInspect

type GoaContainerInspect struct {
	// The arguments to the command being run
	Args []string `form:"args" json:"args" yaml:"args" xml:"args"`
	// The time the container was created
	Created time.Time `form:"created" json:"created" yaml:"created" xml:"created"`
	// ID
	ID int `form:"id" json:"id" yaml:"id" xml:"id"`
	// The name of the image to use when creating the container
	Image string `form:"image" json:"image" yaml:"image" xml:"image"`
	// The container's image ID
	ImageID string `form:"imageID" json:"imageID" yaml:"imageID" xml:"imageID"`
	// Assign the specified name to the container. Must match /?[a-zA-Z0-9_-]+.
	Name string `form:"name" json:"name" yaml:"name" xml:"name"`
	// The path to the command being run
	Path     string                       `form:"path" json:"path" yaml:"path" xml:"path"`
	RawState *GoaContainerInspectRawState `form:"raw_state" json:"raw_state" yaml:"raw_state" xml:"raw_state"`
	Status   string                       `form:"status" json:"status" yaml:"status" xml:"status"`
	// Paths to mount volumes in
	Volumes []string `form:"volumes" json:"volumes" yaml:"volumes" xml:"volumes"`
}

GoaContainerInspect media type (default view)

Identifier: vpn.application/goa.container.inspect; view=default

func (*GoaContainerInspect) Validate

func (mt *GoaContainerInspect) Validate() (err error)

Validate validates the GoaContainerInspect media type instance.

type GoaContainerInspectRawState

type GoaContainerInspectRawState struct {
	Dead       bool      `form:"dead" json:"dead" yaml:"dead" xml:"dead"`
	ExitCode   int       `form:"exitCode" json:"exitCode" yaml:"exitCode" xml:"exitCode"`
	FinishedAt time.Time `form:"finishedAt" json:"finishedAt" yaml:"finishedAt" xml:"finishedAt"`
	OomKilled  bool      `form:"oomKilled" json:"oomKilled" yaml:"oomKilled" xml:"oomKilled"`
	Paused     bool      `form:"paused" json:"paused" yaml:"paused" xml:"paused"`
	Pid        int       `form:"pid" json:"pid" yaml:"pid" xml:"pid"`
	Restarting bool      `form:"restarting" json:"restarting" yaml:"restarting" xml:"restarting"`
	Running    bool      `form:"running" json:"running" yaml:"running" xml:"running"`
	StartedAt  time.Time `form:"startedAt" json:"startedAt" yaml:"startedAt" xml:"startedAt"`
	Status     string    `form:"status" json:"status" yaml:"status" xml:"status"`
}

GoaContainerInspectRaw_state media type (default view)

Identifier: vnd.application/goa.container.inspect.raw_state; view=default

func (*GoaContainerInspectRawState) Validate

func (mt *GoaContainerInspectRawState) Validate() (err error)

Validate validates the GoaContainerInspectRawState media type instance.

type GoaContainerListEach

type GoaContainerListEach struct {
	// Command to run when starting the container
	Command string `form:"command" json:"command" yaml:"command" xml:"command"`
	// The time the container was created
	Created time.Time `form:"created" json:"created" yaml:"created" xml:"created"`
	// ID
	ID int `form:"id" json:"id" yaml:"id" xml:"id"`
	// The name of the image to use when creating the container
	Image string `form:"image" json:"image" yaml:"image" xml:"image"`
	// The container's image ID
	ImageID string `form:"imageID" json:"imageID" yaml:"imageID" xml:"imageID"`
	// Assign the specified name to the container. Must match /?[a-zA-Z0-9_-]+.
	Name   string `form:"name" json:"name" yaml:"name" xml:"name"`
	Status string `form:"status" json:"status" yaml:"status" xml:"status"`
	// Paths to mount volumes in
	Volumes []string `form:"volumes" json:"volumes" yaml:"volumes" xml:"volumes"`
}

GoaContainerListEach media type (default view)

Identifier: vpn.application/goa.container.list.each; view=default

func (*GoaContainerListEach) Validate

func (mt *GoaContainerListEach) Validate() (err error)

Validate validates the GoaContainerListEach media type instance.

type GoaContainerListEachCollection

type GoaContainerListEachCollection []*GoaContainerListEach

GoaContainerListEachCollection is the media type for an array of GoaContainerListEach (default view)

Identifier: vpn.application/goa.container.list.each; type=collection; view=default

func (GoaContainerListEachCollection) Validate

func (mt GoaContainerListEachCollection) Validate() (err error)

Validate validates the GoaContainerListEachCollection media type instance.

type GoaUserAuthorizedkey

type GoaUserAuthorizedkey struct {
	Key   string `form:"key" json:"key" yaml:"key" xml:"key"`
	Label string `form:"label" json:"label" yaml:"label" xml:"label"`
}

GoaUserAuthorizedkey media type (default view)

Identifier: vpn.application/goa.user.authorizedkey; view=default

func (*GoaUserAuthorizedkey) Validate

func (mt *GoaUserAuthorizedkey) Validate() (err error)

Validate validates the GoaUserAuthorizedkey media type instance.

type GoaUserAuthorizedkeyCollection

type GoaUserAuthorizedkeyCollection []*GoaUserAuthorizedkey

GoaUserAuthorizedkeyCollection is the media type for an array of GoaUserAuthorizedkey (default view)

Identifier: vpn.application/goa.user.authorizedkey; type=collection; view=default

func (GoaUserAuthorizedkeyCollection) Validate

func (mt GoaUserAuthorizedkeyCollection) Validate() (err error)

Validate validates the GoaUserAuthorizedkeyCollection media type instance.

type GoaUserConfig

type GoaUserConfig struct {
	AuthorizedKeys GoaUserAuthorizedkeyCollection `form:"authorizedKeys" json:"authorizedKeys" yaml:"authorizedKeys" xml:"authorizedKeys"`
	DefaultShell   string                         `form:"defaultShell" json:"defaultShell" yaml:"defaultShell" xml:"defaultShell"`
}

GoaUserConfig media type (default view)

Identifier: vpn.application/goa.user.config; view=default

func (*GoaUserConfig) Validate

func (mt *GoaUserConfig) Validate() (err error)

Validate validates the GoaUserConfig media type instance.

type GoaUserDefaultshell

type GoaUserDefaultshell struct {
	DefaultShell string `form:"defaultShell" json:"defaultShell" yaml:"defaultShell" xml:"defaultShell"`
}

GoaUserDefaultshell media type (default view)

Identifier: vpn.application/goa.user.defaultshell; view=default

func (*GoaUserDefaultshell) Validate

func (mt *GoaUserDefaultshell) Validate() (err error)

Validate validates the GoaUserDefaultshell media type instance.

type InspectContainerContext

type InspectContainerContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	ID string
}

InspectContainerContext provides the container inspect action context.

func NewInspectContainerContext

func NewInspectContainerContext(ctx context.Context, r *http.Request, service *goa.Service) (*InspectContainerContext, error)

NewInspectContainerContext parses the incoming request URL and body, performs validations and creates the context used by the container controller inspect action.

func (*InspectContainerContext) InternalServerError

func (ctx *InspectContainerContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*InspectContainerContext) NotFound

func (ctx *InspectContainerContext) NotFound() error

NotFound sends a HTTP response with status code 404.

func (*InspectContainerContext) OK

OK sends a HTTP response with status code 200.

type ListAuthorizedKeysUserContext

type ListAuthorizedKeysUserContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
}

ListAuthorizedKeysUserContext provides the user listAuthorizedKeys action context.

func NewListAuthorizedKeysUserContext

func NewListAuthorizedKeysUserContext(ctx context.Context, r *http.Request, service *goa.Service) (*ListAuthorizedKeysUserContext, error)

NewListAuthorizedKeysUserContext parses the incoming request URL and body, performs validations and creates the context used by the user controller listAuthorizedKeys action.

func (*ListAuthorizedKeysUserContext) InternalServerError

func (ctx *ListAuthorizedKeysUserContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*ListAuthorizedKeysUserContext) NotFound

func (ctx *ListAuthorizedKeysUserContext) NotFound() error

NotFound sends a HTTP response with status code 404.

func (*ListAuthorizedKeysUserContext) OK

OK sends a HTTP response with status code 200.

type ListContainerContext

type ListContainerContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
}

ListContainerContext provides the container list action context.

func NewListContainerContext

func NewListContainerContext(ctx context.Context, r *http.Request, service *goa.Service) (*ListContainerContext, error)

NewListContainerContext parses the incoming request URL and body, performs validations and creates the context used by the container controller list action.

func (*ListContainerContext) InternalServerError

func (ctx *ListContainerContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*ListContainerContext) OK

OK sends a HTTP response with status code 200.

type LogsContainerContext

type LogsContainerContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	Follow     bool
	ID         string
	Since      *time.Time
	Stderr     bool
	Stdout     bool
	Tail       string
	Timestamps bool
	Until      *time.Time
}

LogsContainerContext provides the container logs action context.

func NewLogsContainerContext

func NewLogsContainerContext(ctx context.Context, r *http.Request, service *goa.Service) (*LogsContainerContext, error)

NewLogsContainerContext parses the incoming request URL and body, performs validations and creates the context used by the container controller logs action.

func (*LogsContainerContext) InternalServerError

func (ctx *LogsContainerContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*LogsContainerContext) NotFound

func (ctx *LogsContainerContext) NotFound(r error) error

NotFound sends a HTTP response with status code 404.

type RemoveAuthorizedKeysUserContext

type RemoveAuthorizedKeysUserContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	Label string
}

RemoveAuthorizedKeysUserContext provides the user removeAuthorizedKeys action context.

func NewRemoveAuthorizedKeysUserContext

func NewRemoveAuthorizedKeysUserContext(ctx context.Context, r *http.Request, service *goa.Service) (*RemoveAuthorizedKeysUserContext, error)

NewRemoveAuthorizedKeysUserContext parses the incoming request URL and body, performs validations and creates the context used by the user controller removeAuthorizedKeys action.

func (*RemoveAuthorizedKeysUserContext) InternalServerError

func (ctx *RemoveAuthorizedKeysUserContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*RemoveAuthorizedKeysUserContext) NoContent

func (ctx *RemoveAuthorizedKeysUserContext) NoContent() error

NoContent sends a HTTP response with status code 204.

func (*RemoveAuthorizedKeysUserContext) NotFound

func (ctx *RemoveAuthorizedKeysUserContext) NotFound() error

NotFound sends a HTTP response with status code 404.

type RemoveContainerContext

type RemoveContainerContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	Force bool
	ID    string
}

RemoveContainerContext provides the container remove action context.

func NewRemoveContainerContext

func NewRemoveContainerContext(ctx context.Context, r *http.Request, service *goa.Service) (*RemoveContainerContext, error)

NewRemoveContainerContext parses the incoming request URL and body, performs validations and creates the context used by the container controller remove action.

func (*RemoveContainerContext) InternalServerError

func (ctx *RemoveContainerContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*RemoveContainerContext) NoContent

func (ctx *RemoveContainerContext) NoContent() error

NoContent sends a HTTP response with status code 204.

func (*RemoveContainerContext) NotFound

func (ctx *RemoveContainerContext) NotFound() error

NotFound sends a HTTP response with status code 404.

func (*RemoveContainerContext) RunningContainer

func (ctx *RemoveContainerContext) RunningContainer() error

RunningContainer sends a HTTP response with status code 409.

type SetAuthorizedKeysUserContext

type SetAuthorizedKeysUserContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	Payload SetAuthorizedKeysUserPayload
}

SetAuthorizedKeysUserContext provides the user setAuthorizedKeys action context.

func NewSetAuthorizedKeysUserContext

func NewSetAuthorizedKeysUserContext(ctx context.Context, r *http.Request, service *goa.Service) (*SetAuthorizedKeysUserContext, error)

NewSetAuthorizedKeysUserContext parses the incoming request URL and body, performs validations and creates the context used by the user controller setAuthorizedKeys action.

func (*SetAuthorizedKeysUserContext) InternalServerError

func (ctx *SetAuthorizedKeysUserContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*SetAuthorizedKeysUserContext) NoContent

func (ctx *SetAuthorizedKeysUserContext) NoContent() error

NoContent sends a HTTP response with status code 204.

type SetAuthorizedKeysUserPayload

type SetAuthorizedKeysUserPayload []*UserAuthorizedKey

SetAuthorizedKeysUserPayload is the user setAuthorizedKeys action payload.

func (SetAuthorizedKeysUserPayload) Validate

func (payload SetAuthorizedKeysUserPayload) Validate() (err error)

Validate runs the validation rules defined in the design.

type SetConfigContainerContext

type SetConfigContainerContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	ID      string
	Payload *ContainerConfig
}

SetConfigContainerContext provides the container setConfig action context.

func NewSetConfigContainerContext

func NewSetConfigContainerContext(ctx context.Context, r *http.Request, service *goa.Service) (*SetConfigContainerContext, error)

NewSetConfigContainerContext parses the incoming request URL and body, performs validations and creates the context used by the container controller setConfig action.

func (*SetConfigContainerContext) InternalServerError

func (ctx *SetConfigContainerContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*SetConfigContainerContext) NoContent

func (ctx *SetConfigContainerContext) NoContent() error

NoContent sends a HTTP response with status code 204.

func (*SetConfigContainerContext) NotFound

func (ctx *SetConfigContainerContext) NotFound() error

NotFound sends a HTTP response with status code 404.

type SetDefaultShellUserContext

type SetDefaultShellUserContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	DefaultShell string
}

SetDefaultShellUserContext provides the user setDefaultShell action context.

func NewSetDefaultShellUserContext

func NewSetDefaultShellUserContext(ctx context.Context, r *http.Request, service *goa.Service) (*SetDefaultShellUserContext, error)

NewSetDefaultShellUserContext parses the incoming request URL and body, performs validations and creates the context used by the user controller setDefaultShell action.

func (*SetDefaultShellUserContext) InternalServerError

func (ctx *SetDefaultShellUserContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*SetDefaultShellUserContext) NoContent

func (ctx *SetDefaultShellUserContext) NoContent() error

NoContent sends a HTTP response with status code 204.

type StartContainerContext

type StartContainerContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	ID string
}

StartContainerContext provides the container start action context.

func NewStartContainerContext

func NewStartContainerContext(ctx context.Context, r *http.Request, service *goa.Service) (*StartContainerContext, error)

NewStartContainerContext parses the incoming request URL and body, performs validations and creates the context used by the container controller start action.

func (*StartContainerContext) InternalServerError

func (ctx *StartContainerContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*StartContainerContext) NoContent

func (ctx *StartContainerContext) NoContent() error

NoContent sends a HTTP response with status code 204.

func (*StartContainerContext) NotFound

func (ctx *StartContainerContext) NotFound() error

NotFound sends a HTTP response with status code 404.

type StopContainerContext

type StopContainerContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	ID string
}

StopContainerContext provides the container stop action context.

func NewStopContainerContext

func NewStopContainerContext(ctx context.Context, r *http.Request, service *goa.Service) (*StopContainerContext, error)

NewStopContainerContext parses the incoming request URL and body, performs validations and creates the context used by the container controller stop action.

func (*StopContainerContext) InternalServerError

func (ctx *StopContainerContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*StopContainerContext) NoContent

func (ctx *StopContainerContext) NoContent() error

NoContent sends a HTTP response with status code 204.

func (*StopContainerContext) NotFound

func (ctx *StopContainerContext) NotFound() error

NotFound sends a HTTP response with status code 404.

type SwaggerController

type SwaggerController interface {
	goa.Muxer
	goa.FileServer
}

SwaggerController is the controller interface for the Swagger actions.

type UploadContainerContext

type UploadContainerContext struct {
	context.Context
	*goa.ResponseData
	*goa.RequestData
	ID      string
	Payload *UploadPayload
}

UploadContainerContext provides the container upload action context.

func NewUploadContainerContext

func NewUploadContainerContext(ctx context.Context, r *http.Request, service *goa.Service) (*UploadContainerContext, error)

NewUploadContainerContext parses the incoming request URL and body, performs validations and creates the context used by the container controller upload action.

func (*UploadContainerContext) BadRequest

func (ctx *UploadContainerContext) BadRequest(r error) error

BadRequest sends a HTTP response with status code 400.

func (*UploadContainerContext) InternalServerError

func (ctx *UploadContainerContext) InternalServerError(r error) error

InternalServerError sends a HTTP response with status code 500.

func (*UploadContainerContext) NoContent

func (ctx *UploadContainerContext) NoContent() error

NoContent sends a HTTP response with status code 204.

func (*UploadContainerContext) NotFound

func (ctx *UploadContainerContext) NotFound(r error) error

NotFound sends a HTTP response with status code 404.

func (*UploadContainerContext) RequestEntityTooLarge

func (ctx *UploadContainerContext) RequestEntityTooLarge() error

RequestEntityTooLarge sends a HTTP response with status code 413.

type UploadPayload

type UploadPayload struct {
	// Allow for a existing directory to be replaced by a file
	AllowOverwrite bool `form:"allowOverwrite" json:"allowOverwrite" yaml:"allowOverwrite" xml:"allowOverwrite"`
	// Copy all uid/gid information
	CopyUIDGID bool `form:"copyUIDGID" json:"copyUIDGID" yaml:"copyUIDGID" xml:"copyUIDGID"`
	// File tar archive
	Data *multipart.FileHeader `form:"data" json:"data" yaml:"data" xml:"data"`
	// Path in the container to save files
	Path string `form:"path" json:"path" yaml:"path" xml:"path"`
}

UploadPayload user type.

func (*UploadPayload) Validate

func (ut *UploadPayload) Validate() (err error)

Validate validates the UploadPayload type instance.

type UserAuthorizedKey

type UserAuthorizedKey struct {
	Key   string `form:"key" json:"key" yaml:"key" xml:"key"`
	Label string `form:"label" json:"label" yaml:"label" xml:"label"`
}

UserAuthorizedKey user type.

func (*UserAuthorizedKey) Validate

func (ut *UserAuthorizedKey) Validate() (err error)

Validate validates the UserAuthorizedKey type instance.

type UserConfig

type UserConfig struct {
	AuthorizedKeys []*UserAuthorizedKey `` /* 126-byte string literal not displayed */
	DefaultShell   *string              `form:"defaultShell,omitempty" json:"defaultShell,omitempty" yaml:"defaultShell,omitempty" xml:"defaultShell,omitempty"`
}

UserConfig user type.

func (*UserConfig) Validate

func (ut *UserConfig) Validate() (err error)

Validate validates the UserConfig type instance.

type UserController

type UserController interface {
	goa.Muxer
	AddAuthorizedKeys(*AddAuthorizedKeysUserContext) error
	GetConfig(*GetConfigUserContext) error
	GetDefaultShell(*GetDefaultShellUserContext) error
	ListAuthorizedKeys(*ListAuthorizedKeysUserContext) error
	RemoveAuthorizedKeys(*RemoveAuthorizedKeysUserContext) error
	SetAuthorizedKeys(*SetAuthorizedKeysUserContext) error
	SetDefaultShell(*SetDefaultShellUserContext) error
}

UserController is the controller interface for the User actions.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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