Class ContainerExecDecorator

java.lang.Object
hudson.LauncherDecorator
org.csanchez.jenkins.plugins.kubernetes.pipeline.ContainerExecDecorator
All Implemented Interfaces:
ExtensionPoint, Closeable, Serializable, AutoCloseable

public class ContainerExecDecorator extends LauncherDecorator implements Serializable, Closeable
This decorator interacts directly with the Kubernetes exec API to run commands inside a container. It does not use the Jenkins agent to execute commands.
See Also:
  • Field Details

    • COMMAND_FINISHED_TIMEOUT_MS

      public static final int COMMAND_FINISHED_TIMEOUT_MS
      time in milliseconds to wait for checking whether the process immediately returned
      See Also:
  • Constructor Details

    • ContainerExecDecorator

      public ContainerExecDecorator()
    • ContainerExecDecorator

      @Deprecated public ContainerExecDecorator(io.fabric8.kubernetes.client.KubernetesClient client, String podName, String containerName, String namespace, org.jenkinsci.plugins.workflow.steps.EnvironmentExpander environmentExpander, FilePath ws)
      Deprecated.
    • ContainerExecDecorator

      @Deprecated public ContainerExecDecorator(io.fabric8.kubernetes.client.KubernetesClient client, String podName, String containerName, String namespace, org.jenkinsci.plugins.workflow.steps.EnvironmentExpander environmentExpander)
      Deprecated.
    • ContainerExecDecorator

      @Deprecated public ContainerExecDecorator(io.fabric8.kubernetes.client.KubernetesClient client, String podName, String containerName, String namespace)
      Deprecated.
    • ContainerExecDecorator

      @Deprecated public ContainerExecDecorator(io.fabric8.kubernetes.client.KubernetesClient client, String podName, String containerName, AtomicBoolean alive, CountDownLatch started, CountDownLatch finished, String namespace)
      Deprecated.
    • ContainerExecDecorator

      @Deprecated public ContainerExecDecorator(io.fabric8.kubernetes.client.KubernetesClient client, String podName, String containerName, AtomicBoolean alive, CountDownLatch started, CountDownLatch finished)
      Deprecated.
    • ContainerExecDecorator

      @Deprecated public ContainerExecDecorator(io.fabric8.kubernetes.client.KubernetesClient client, String podName, String containerName, String path, AtomicBoolean alive, CountDownLatch started, CountDownLatch finished)
      Deprecated.
  • Method Details

    • getClient

      @Deprecated public io.fabric8.kubernetes.client.KubernetesClient getClient()
      Deprecated.
    • setClient

      @Deprecated public void setClient(io.fabric8.kubernetes.client.KubernetesClient client)
      Deprecated.
    • getPodName

      @Deprecated public String getPodName()
      Deprecated.
    • setPodName

      @Deprecated public void setPodName(String podName)
      Deprecated.
    • getNamespace

      @Deprecated public String getNamespace()
      Deprecated.
    • setNamespace

      @Deprecated public void setNamespace(String namespace)
      Deprecated.
    • getContainerName

      public String getContainerName()
    • setContainerName

      public void setContainerName(String containerName)
    • getEnvironmentExpander

      public org.jenkinsci.plugins.workflow.steps.EnvironmentExpander getEnvironmentExpander()
    • setEnvironmentExpander

      public void setEnvironmentExpander(org.jenkinsci.plugins.workflow.steps.EnvironmentExpander environmentExpander)
    • getGlobalVars

      public EnvVars getGlobalVars()
    • setGlobalVars

      public void setGlobalVars(EnvVars globalVars)
    • setRunContextEnvVars

      public void setRunContextEnvVars(EnvVars rcVars)
    • getRunContextEnvVars

      public EnvVars getRunContextEnvVars()
    • setShell

      public void setShell(String shell)
    • getNodeContext

      public org.csanchez.jenkins.plugins.kubernetes.pipeline.KubernetesNodeContext getNodeContext()
    • setNodeContext

      public void setNodeContext(org.csanchez.jenkins.plugins.kubernetes.pipeline.KubernetesNodeContext nodeContext)
    • decorate

      public Launcher decorate(Launcher launcher, Node node)
      Specified by:
      decorate in class LauncherDecorator
    • close

      public void close() throws IOException
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface Closeable
      Throws:
      IOException
    • setKubernetesClient

      @Deprecated public void setKubernetesClient(io.fabric8.kubernetes.client.KubernetesClient client)
      Deprecated.