Documentation ¶
Index ¶
- type AWSEcs
- func (s *AWSEcs) CreateCluster(ctx context.Context, cluster string) error
- func (s *AWSEcs) CreateService(ctx context.Context, opts *containersvc.CreateServiceOptions) error
- func (s *AWSEcs) CreateServiceVolume(ctx context.Context, service string, memberName string, volumeID string, ...) (existingVolumeID string, err error)
- func (s *AWSEcs) DeleteCluster(ctx context.Context, cluster string) error
- func (s *AWSEcs) DeleteService(ctx context.Context, cluster string, service string) error
- func (s *AWSEcs) DeleteServiceVolume(ctx context.Context, service string, memberName string, journal bool) error
- func (s *AWSEcs) DeleteTask(ctx context.Context, cluster string, service string, taskType string) error
- func (s *AWSEcs) DeregisterContainerInstance(ctx context.Context, cluster string, instance string) error
- func (s *AWSEcs) GetContainerSvcType() string
- func (s *AWSEcs) GetServiceStatus(ctx context.Context, cluster string, service string) (*common.ServiceStatus, error)
- func (s *AWSEcs) GetServiceTask(ctx context.Context, cluster string, service string, ...) (taskID string, err error)
- func (s *AWSEcs) GetTaskContainerInstance(ctx context.Context, cluster string, taskArn string) (containerInstanceArn string, err error)
- func (s *AWSEcs) GetTaskStatus(ctx context.Context, cluster string, taskArn string) (*common.TaskStatus, error)
- func (s *AWSEcs) IsClusterExist(ctx context.Context, cluster string) (bool, error)
- func (s *AWSEcs) IsServiceExist(ctx context.Context, cluster string, service string) (bool, error)
- func (s *AWSEcs) ListActiveServiceTasks(ctx context.Context, cluster string, service string) (taskIDs map[string]bool, err error)
- func (s *AWSEcs) ListActiveServiceTasksWithLimit(ctx context.Context, cluster string, service string, limit int64) (taskIDs map[string]bool, err error)
- func (s *AWSEcs) RollingRestartService(ctx context.Context, cluster string, service string, ...) error
- func (s *AWSEcs) RunTask(ctx context.Context, opts *containersvc.RunTaskOptions) (taskID string, err error)
- func (s *AWSEcs) ScaleService(ctx context.Context, cluster string, service string, desiredCount int64) error
- func (s *AWSEcs) StopService(ctx context.Context, cluster string, service string) error
- func (s *AWSEcs) UpdateService(ctx context.Context, opts *containersvc.UpdateServiceOptions) error
- func (s *AWSEcs) WaitServiceRunning(ctx context.Context, cluster string, service string, replicas int64, ...) error
- func (s *AWSEcs) WaitTaskComplete(ctx context.Context, cluster string, taskArn string, maxWaitSeconds int64) error
- type EcsInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AWSEcs ¶
type AWSEcs struct {
// contains filtered or unexported fields
}
AWSEcs serves the ECS related functions
func (*AWSEcs) CreateCluster ¶
CreateCluster creates an ECS cluster
func (*AWSEcs) CreateService ¶
func (s *AWSEcs) CreateService(ctx context.Context, opts *containersvc.CreateServiceOptions) error
CreateService creates a ECS service
func (*AWSEcs) CreateServiceVolume ¶ added in v0.9.3
func (s *AWSEcs) CreateServiceVolume(ctx context.Context, service string, memberName string, volumeID string, volumeSizeGB int64, journal bool) (existingVolumeID string, err error)
CreateServiceVolume is a non-op for ecs.
func (*AWSEcs) DeleteCluster ¶
DeleteCluster deletes the ECS cluster
func (*AWSEcs) DeleteService ¶
DeleteService deletes the ECS service and TaskDefinition
func (*AWSEcs) DeleteServiceVolume ¶ added in v0.9.3
func (s *AWSEcs) DeleteServiceVolume(ctx context.Context, service string, memberName string, journal bool) error
DeleteServiceVolume is a non-op for ecs.
func (*AWSEcs) DeleteTask ¶
func (s *AWSEcs) DeleteTask(ctx context.Context, cluster string, service string, taskType string) error
DeleteTask deletes the task definition
func (*AWSEcs) DeregisterContainerInstance ¶
func (s *AWSEcs) DeregisterContainerInstance(ctx context.Context, cluster string, instance string) error
DeregisterContainerInstance deregisters the container instance from ECS cluster
func (*AWSEcs) GetContainerSvcType ¶ added in v0.9.3
GetContainerSvcType gets the containersvc type.
func (*AWSEcs) GetServiceStatus ¶
func (s *AWSEcs) GetServiceStatus(ctx context.Context, cluster string, service string) (*common.ServiceStatus, error)
GetServiceStatus returns the ServiceStatus.
func (*AWSEcs) GetServiceTask ¶
func (s *AWSEcs) GetServiceTask(ctx context.Context, cluster string, service string, containerInstanceID string) (taskID string, err error)
GetServiceTask gets the task running on the containerInstanceID
func (*AWSEcs) GetTaskContainerInstance ¶
func (s *AWSEcs) GetTaskContainerInstance(ctx context.Context, cluster string, taskArn string) (containerInstanceArn string, err error)
GetTaskContainerInstance returns the ContainerInstanceArn the task runs on
func (*AWSEcs) GetTaskStatus ¶
func (s *AWSEcs) GetTaskStatus(ctx context.Context, cluster string, taskArn string) (*common.TaskStatus, error)
GetTaskStatus returns the task's status.
func (*AWSEcs) IsClusterExist ¶
IsClusterExist checks whether the cluster exists.
func (*AWSEcs) IsServiceExist ¶
IsServiceExist checks whether the service exists.
func (*AWSEcs) ListActiveServiceTasks ¶
func (s *AWSEcs) ListActiveServiceTasks(ctx context.Context, cluster string, service string) (taskIDs map[string]bool, err error)
ListActiveServiceTasks lists all running and pending tasks of the service
func (*AWSEcs) ListActiveServiceTasksWithLimit ¶
func (s *AWSEcs) ListActiveServiceTasksWithLimit(ctx context.Context, cluster string, service string, limit int64) (taskIDs map[string]bool, err error)
ListActiveServiceTasksWithLimit lists all tasks of the service by pagination, called by unit test only.
func (*AWSEcs) RollingRestartService ¶ added in v0.9.4
func (s *AWSEcs) RollingRestartService(ctx context.Context, cluster string, service string, opts *containersvc.RollingRestartOptions) error
RollingRestartService restarts the service task one after the other.
func (*AWSEcs) RunTask ¶
func (s *AWSEcs) RunTask(ctx context.Context, opts *containersvc.RunTaskOptions) (taskID string, err error)
RunTask starts a new task. ECS limits "startedBy" up to 36 letters.
func (*AWSEcs) ScaleService ¶ added in v0.9.2
func (s *AWSEcs) ScaleService(ctx context.Context, cluster string, service string, desiredCount int64) error
ScaleService scales the service containers up/down to the desiredCount.
func (*AWSEcs) StopService ¶
StopService stops all service containers
func (*AWSEcs) UpdateService ¶ added in v0.9.5
func (s *AWSEcs) UpdateService(ctx context.Context, opts *containersvc.UpdateServiceOptions) error
UpdateService updates the service
type EcsInfo ¶
type EcsInfo struct {
// contains filtered or unexported fields
}