exec

package
v0.0.0-...-fcf97bc Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2024 License: Zlib Imports: 30 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DockerComposeStackService

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

DockerComposeStackService represents a service for managing stacks by using the Docker binary.

func NewDockerComposeStackService

func NewDockerComposeStackService(binaryPath string) *DockerComposeStackService

NewDockerComposeStackService initializes a new DockerStackService service. It also updates the configuration of the Docker CLI binary.

func (*DockerComposeStackService) Deploy

func (service *DockerComposeStackService) Deploy(ctx context.Context, name string, filePaths []string, options deployer.DeployOptions) error

Deploy executes the docker stack deploy command.

func (*DockerComposeStackService) GetEdgeStacks

func (service *DockerComposeStackService) GetEdgeStacks(ctx context.Context) ([]agent.EdgeStack, error)

func (*DockerComposeStackService) Pull

func (service *DockerComposeStackService) Pull(ctx context.Context, name string, filePaths []string, options deployer.PullOptions) error

Pull executes the docker pull command.

func (*DockerComposeStackService) Remove

func (service *DockerComposeStackService) Remove(ctx context.Context, name string, filePaths []string, options deployer.RemoveOptions) error

Remove executes the docker stack rm command.

func (*DockerComposeStackService) Validate

func (service *DockerComposeStackService) Validate(ctx context.Context, name string, filePaths []string, options deployer.ValidateOptions) error

Validate executes docker config command to validate file format

func (*DockerComposeStackService) WaitForStatus

type DockerSwarmDeployOpts

type DockerSwarmDeployOpts struct {
	Prune bool
}

type DockerSwarmStackService

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

DockerSwarmStackService represents a service for managing stacks by using the Docker binary.

func NewDockerSwarmStackService

func NewDockerSwarmStackService(binaryPath string) *DockerSwarmStackService

NewDockerSwarmStackService initializes a new DockerStackService service. It also updates the configuration of the Docker CLI binary.

func (*DockerSwarmStackService) Deploy

func (service *DockerSwarmStackService) Deploy(ctx context.Context, name string, filePaths []string, options deployer.DeployOptions) error

Deploy executes the docker stack deploy command.

func (*DockerSwarmStackService) GetEdgeStacks

func (service *DockerSwarmStackService) GetEdgeStacks(ctx context.Context) ([]agent.EdgeStack, error)

func (*DockerSwarmStackService) Pull

func (service *DockerSwarmStackService) Pull(ctx context.Context, name string, filePaths []string, options deployer.PullOptions) error

Pull is a dummy method for Swarm

func (*DockerSwarmStackService) Remove

func (service *DockerSwarmStackService) Remove(ctx context.Context, name string, filePaths []string, options deployer.RemoveOptions) error

Remove executes the docker stack rm command.

func (*DockerSwarmStackService) Validate

func (service *DockerSwarmStackService) Validate(ctx context.Context, name string, filePaths []string, options deployer.ValidateOptions) error

Validate uses compose to validate the stack files

func (*DockerSwarmStackService) WaitForStatus

type KubernetesDeployer

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

KubernetesDeployer represents a service to deploy resources inside a Kubernetes environment.

func NewKubernetesDeployer

func NewKubernetesDeployer(binaryPath string, kubeClient *kubernetes.KubeClient) *KubernetesDeployer

NewKubernetesDeployer initializes a new KubernetesDeployer service.

func (*KubernetesDeployer) Deploy

func (deployer *KubernetesDeployer) Deploy(ctx context.Context, name string, filePaths []string, options deployer.DeployOptions) error

Deploy will deploy a Kubernetes manifest inside the default namespace it will use kubectl to deploy the manifest. kubectl uses in-cluster config.

func (*KubernetesDeployer) DeployRawConfig

func (deployer *KubernetesDeployer) DeployRawConfig(token, config string, namespace string) ([]byte, error)

DeployRawConfig will deploy a Kubernetes manifest inside a specific namespace it will use kubectl to deploy the manifest and receives a raw config. kubectl uses in-cluster config.

func (*KubernetesDeployer) GetEdgeStacks

func (service *KubernetesDeployer) GetEdgeStacks(ctx context.Context) ([]agent.EdgeStack, error)

func (*KubernetesDeployer) Pull

func (deployer *KubernetesDeployer) Pull(ctx context.Context, name string, filePaths []string, options deployer.PullOptions) error

Pull is a dummy method for Kube

func (*KubernetesDeployer) Remove

func (deployer *KubernetesDeployer) Remove(ctx context.Context, name string, filePaths []string, options deployer.RemoveOptions) error

func (*KubernetesDeployer) Validate

func (deployer *KubernetesDeployer) Validate(ctx context.Context, name string, filePaths []string, options deployer.ValidateOptions) error

Validate is a dummy method for Kubernetes manifest validation https://portainer.atlassian.net/browse/EE-6292?focusedCommentId=29674

func (*KubernetesDeployer) WaitForStatus

func (service *KubernetesDeployer) WaitForStatus(ctx context.Context, name string, requiredStatus libstack.Status, options deployer.CheckStatusOptions) libstack.WaitResult

Jump to

Keyboard shortcuts

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