1, docker in accordance with the basic deployment, has been described in detail previously, not much to say here.
2, pull a mirror docker pull jenkins jenkins
3, jenkins view mirror docker images already installed
4, jenkins create a directory mkdir / home / jenkins_home
5, a start jenkins container docker run -d --name jenkins -p 8081: 8080 -v / home / jenkins_home: / home / jenkins_home jenkins
Where 8081: 8080, the internal jenkins port 8080, the server uses port 8081, then map the two together, the time after the visit that the browser is actually still access the server port 8081
6, see jenkins service docker ps | grep jenkins
7, start the server. localhost: 8081 / jenkins
8, inside the container to find the cryptographic
Into the container: docker exec -it jenkins bash
Execute: CAT / var / jenkins_home / Secrets / initialAdminPassword
Find the password, enter the password to the initial interface
9, after the password, restart mirroring docker docker restart {CONTAINER ID}
10, start the server again, jenkins service has been up. Later it is to configure the plug-in problem