Kubernetes plugin

containerLog: Get container log from Kubernetes

name
Name of the container, as specified in containerTemplate.

Type: String

limitBytes (optional)
If set, the number of bytes to read from the server before terminating the log output. This may not display a complete final line of logging, and may return slightly more or slightly less than the specified limit.

Type: int

returnLog (optional)
Return the container log. If not checked, the log will be printed to the build log.

Type: boolean

sinceSeconds (optional)
A relative time in seconds before the current time from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned.

Type: int

tailingLines (optional)
If set, the number of lines from the end of the log to show. If not specified, log is shown from the creation of the container or limited by "sinceSeconds".

Type: int

container: Run build steps in a container

Selects a container of the slave pod so that all shell steps are executed in that container.
name

Type: String

podTemplate: Define a podTemplate to use in the kubernetes plugin

Defines a container inside the kubernetes plugin configuration
label

Type: String

name
The name prefix of the pod.

Type: String

annotations (optional)
Annotations to set on pod metadata
https://kubernetes.io/docs/user-guide/annotations/

Array/List

Nested Object

key
The annotation key.

Type: String

value
The annotation value.

Type: String

cloud (optional)

Type: String

containers (optional)

Array/List

Nested Object

name (optional)

Type: String

image (optional)
Docker image ID for a jenkins JNLP slave. This image is responsible to run a jenkins jnlp bootstrap agent and connect to Jenkins master. Secret key and slave name as well as jenkins callback URL are passed as argument as expected by hudson.remoting.jnlp.Main.

Type: String

alwaysPullImage (optional)

Type: boolean

args (optional)
Arguments to pass to the command. ${computer.jnlpmac} and ${computer.name} are replaced with the slave secret and name respectively.

Type: String

command (optional)
Override the image entrypoint with a different one

Type: String

envVars (optional)
The environment variables to pass to the container.

Array/List

Nested Choice of Objects $class: ContainerEnvVar key::::

+

The environment variable key.

Type: String

value
The environment variable value.

Type: String

$class: KeyValueEnvVar key::::

+

The environment variable key.

Type: String

value
The environment variable value.

Type: String

$class: PodEnvVar key::::

+

The environment variable key.

Type: String

value
The environment variable value.

Type: String

$class: SecretEnvVar key::::

+

The environment variable key.

Type: String

secretName
Name of secret to lookup from Kubernetes.

Type: String

secretKey
Key of secret to lookup from Kubernetes.

Type: String

livenessProbe (optional)

Nested Object

execArgs
Command executed by the liveness probe.

Type: String

timeoutSeconds

Type: int

initialDelaySeconds

Type: int

failureThreshold

Type: int

periodSeconds

Type: int

successThreshold

Type: int

ports (optional)

Array/List

Nested Object

name (optional)
The name of the port

Type: String

containerPort (optional)
Port to expose into the pod

Type: int

hostPort (optional)
Port to expose onto the host

Type: int

privileged (optional)
Flag to mark the container as privileged.

Type: boolean

resourceLimitCpu (optional)
Kubernetes Resources Limit of CPU This value can be set to control the CPU resource limit passed when creating the jenkins slave docker container in Kubernetes. Unlike a resource request, this is the upper limit of resources used by your Jenkins Slave container. When left blank, the defaults of your Kubernetes cluster will be used. For more info, see the Kubernetes docs. e.g. `500m`.

Type: String

resourceLimitMemory (optional)
Kubernetes Resources Limit of Memory This value can be set to control the memory resource limit passed when creating the jenkins slave docker container in Kubernetes. Unlike a resource request, this is the upper limit of resources used by your Jenkins Slave container. When left blank, the defaults of your Kubernetes cluster will be used. For more info, see the Kubernetes docs. e.g. `250Mi`.

Type: String

resourceRequestCpu (optional)
Kubernetes Resources Request of CPU This value can be set to control the CPU resources requested when creating the jenkins slave docker container in Kubernetes. When left blank, the defaults of your Kubernetes cluster will be used. For more info, see the Kubernetes docs. e.g. `500m`.

Type: String

resourceRequestMemory (optional)
Kubernetes Resources Request of Memory This value can be set to control the memory resources requested when creating the jenkins slave docker container in Kubernetes. When left blank, the defaults of your Kubernetes cluster will be used. For more info, see the Kubernetes docs. e.g. `250Mi`.

Type: String

ttyEnabled (optional)

Type: boolean

workingDir (optional)
Path to the root of the workspace from the view point of this node, such as "/home/jenkins", this need not be absolute provided that the launcher establishes a consistent working directory, such as "./.jenkins-slave".

Type: String

envVars (optional)

Array/List

Nested Choice of Objects $class: ContainerEnvVar key:::

+

The environment variable key.

Type: String

value
The environment variable value.

Type: String

$class: KeyValueEnvVar key:::

+

The environment variable key.

Type: String

value
The environment variable value.

Type: String

$class: PodEnvVar key:::

+

The environment variable key.

Type: String

value
The environment variable value.

Type: String

$class: SecretEnvVar key:::

+

The environment variable key.

Type: String

secretName
Name of secret to lookup from Kubernetes.

Type: String

secretKey
Key of secret to lookup from Kubernetes.

Type: String

idleMinutes (optional)
Time in minutes to retain slave when idle

Type: int

imagePullSecrets (optional)

Array/List

Type: String

inheritFrom (optional)

Type: String

instanceCap (optional)
Max number of containers to start from this template. If set to empty or negative number it means no limit.

Type: int

namespace (optional)

Type: String

nodeSelector (optional)

Type: String

nodeUsageMode (optional)

Values:

  • NORMAL

  • EXCLUSIVE

serviceAccount (optional)
The service account of the pod.

Type: String

slaveConnectTimeout (optional)

Type: int

volumes (optional)

Array/List

Nested Choice of Objects $class: ConfigMapVolume mountPath:::

+

Path to mount this volume inside the pod.

Type: String

configMapName
The name of the Kubernetes Config Map to mount into the pod.

Type: String

$class: EmptyDirVolume mountPath:::

+

Path to mount this volume inside the pod.

Type: String

memory
Flag for in-memory volume.

Type: boolean

$class: HostPathVolume hostPath:::

+

File or directory on the host node's filesystem to mount into the pod.

Type: String

mountPath
Path to mount this volume inside the pod.

Type: String

$class: NfsVolume serverAddress:::

+

NFS Server Address.

Type: String

serverPath
NFS Server Path.

Type: String

readOnly

Type: boolean

mountPath
Path to mount this volume inside the pod.

Type: String

$class: PersistentVolumeClaim mountPath:::

+

Path to mount this volume inside the pod.

Type: String

claimName
The claim name.

Type: String

readOnly
Flag for read-only volume.

Type: boolean

$class: SecretVolume mountPath:::

+

Path to mount this volume inside the pod.

Type: String

secretName
The name of the Kubernetes Secret to mount into the pod.

Type: String

workingDir (optional)

Type: String

workspaceVolume (optional)

Nested Choice of Objects $class: EmptyDirWorkspaceVolume memory:::

+

Flag for in-memory volume.

Type: boolean

$class: HostPathWorkspaceVolume hostPath:::

+

File or directory on the host node's filesystem to mount into the pod.

Type: String

$class: NfsWorkspaceVolume serverAddress:::

+

NFS Server Address.

Type: String

serverPath
NFS Server Path.

Type: String

readOnly

Type: boolean

$class: PersistentVolumeClaimWorkspaceVolume claimName:::

+

The claim name.

Type: String

readOnly
Flag for read-only volume.

Type: boolean