The following plugin provides functionality available through Pipeline-compatible steps. Read more about how to integrate steps into your Pipeline in the Steps section of the Pipeline Syntax page.

For a list of other such plugins, see the Pipeline Steps Reference page.

Docker Pipeline

dockerFingerprintFrom: Record trace of a Docker image used in FROM

Normally used implicitly by method calls on the docker global variable. Records the fact that a Docker image was built from another.
  • dockerfile
    Workspace-relative path of a Dockerfile which will be parsed for its FROM instruction.
    • Type: String
  • image
    ID or tag of the image which was just built, like --tag of docker build.
    • Type: String
  • buildArgs (optional)
      java.lang.String>
  • toolName (optional)
    • Type: String

dockerFingerprintRun: Record trace of a Docker image run in a container

Normally used implicitly by method calls on the docker global variable. Records the fact that a Docker image was used by this build.
  • containerId
    • Type: String
  • toolName (optional)
    • Type: String

withDockerContainer: Run build steps inside a Docker container

Normally used implicitly by method calls on the docker global variable. Takes an image ID or symbolic name which must already have been pulled locally and starts a container based on that image. Runs all nested sh steps inside that container. The workspace is mounted read-write into the container.
  • image
    • Type: String
  • args (optional)
    Any other arguments to pass to docker run.
    • Type: String
  • toolName (optional)
    • Type: String

withDockerRegistry: Sets up Docker registry endpoint

Normally used implicitly by method calls on the docker global variable. Sets up connection details for a Docker registry.
  • registry
      Nested Object
    • url
      URL to the Docker registry you are using. May be left blank to use the public DockerHub registry (currently https://index.docker.io/v1/).
      • Type: String
    • credentialsId
      • Type: String
  • toolName (optional)
    • Type: String

withDockerServer: Sets up Docker server endpoint

Normally used implicitly by method calls on the docker global variable. Sets up connection details for a Docker server.
  • server
      Nested Object
    • uri
      URI to the Docker Host you are using. May be left blank to use the Docker default (defined by DOCKER_HOST environment variable) (typically unix:///var/run/docker.sock or tcp://127.0.0.1:2376).
      • Type: String
    • credentialsId
      • Type: String

Was this page helpful?

Please submit your feedback about this page through this quick form.

Alternatively, if you don't wish to complete the quick form, you can simply indicate if you found this page helpful?

    


See existing feedback here.