How to find “Docker Host URI” to be used in Jenkins “Docker Plugin”?

前端 未结 4 1703
自闭症患者
自闭症患者 2021-01-11 09:59

Is there any command which we can run and find out the \"Docker Host URI\"? I found some of related questions but didn\'t get it exactly.

4条回答
  •  旧时难觅i
    2021-01-11 10:26

    If your docker running at the same host were you use Jenkins inside a container than you can use unix:///var/run/docker.sock as the “Docker Host URI”, but you must check & obtain the permissions for jenkins user by using:

    sudo groupadd docker
    sudo usermod -aG docker $USER
    sudo chmod a+rwx /var/run/docker.sock
    sudo chmod a+rwx /var/run/docker.pid
    

提交回复
热议问题