The main reference article: https: //blog.csdn.net/fsgsggd/article/details/90675686
It aims summary command, not guidance. As for the configuration requires that you direct point of reference links to learn it.
1. Download the image from the https://hub.docker.com
docker pull jenkins
2. Start container
mkdir / usr / local / Work / Jenkins -p # Create a host mapping directory
chmod 777 /usr/local/work/jenkins
RUN -p Docker 8081: 8080 -p 50001: 50000 -v / usr / local / Work / Jenkins: / var / jenkins_home - name J01 -idt Jenkins # -p port mapping, to the host before the colon
docker logs -f j01 # container has started log for jenkins service started successfully (found 1 issue: time to host a different container)
3. Access Jenkins
http://192.168.118.128:8081 # host IP: 192.168.118.128
Enter code # password file start: / usr / local / work / jenkins / secrets / initialAdminPassword