Docker Community Forums

Share and learn in the Docker community.

Docker: not found from Jenkins pipeline


(Dibyend123) #1

I am Running Jenkins from Docker.I am getting th following error
[NewCIPipeline] Running shell script

  • docker build -t localhost:5000:2 .
    /var/jenkins_home/workspace/NewCIPipeline@tmp/durable-027823c6/script.sh: line 1: docker: not found
    [Pipeline] }

Below is my Pipeline

stage(“dockerbuild”){
steps{
script {
docker.build registry+":1"
}
}
}