
다양한 Docker 관련 플러그인에 공통으로 사용되는 기능을 제공하는 API 플러그인입니다.
ToolInstallationDockerImageExtractor 확장 지점이를 통해 사용자는 한 세트의 엔드포인트/자격 증명을 구성하고 이를 모든 Docker 관련 플러그인에서 사용할 수 있으므로 구성을 보다 DRY하게 유지할 수 있습니다.
일반적인 사용법은 Docker Pipeline Plugin을 참조하세요.
선언적 파이프라인에서 Docker 호스트/데몬 자격 증명을 바인딩하는 방법에 대한 예제:
pipeline {
agent any
tools {
// a bit ugly because there is no `@Symbol` annotation for the DockerTool
// see the discussion about this in PR 77 and PR 52:
// https://github.com/jenkinsci/docker-commons-plugin/pull/77#discussion_r280910822
// https://github.com/jenkinsci/docker-commons-plugin/pull/52
'org.jenkinsci.plugins.docker.commons.tools.DockerTool' '18.09'
}
environment {
DOCKER_CERT_PATH = credentials('id-for-a-docker-cred')
}
stages {
stage('foo') {
steps {
sh "docker version" // DOCKER_CERT_PATH is automatically picked up by the Docker client
}
}
}
}
1.15 및 이전 버전은 릴리스 노트 아카이브를 참조하세요