In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-31 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/02 Report--
It is believed that many inexperienced people have no idea about how to install nexus3 in Docker. Therefore, this article summarizes the causes and solutions of the problem. Through this article, I hope you can solve this problem.
1. Build an environment
CentOS 7.6
Docker 19.03.4
two。 Concrete steps
Find nexus3 Mirror
Docker search nexus3
Console output
[root@xxx] # docker search nexus3NAME DESCRIPTION STARS OFFICIAL AUTOMATEDsonatype/nexus3 Sonatype Nexus Repository Manager 3 693 shifudao/nexus3 clone from nexus3 image but based from openj... 4 [OK] madmuffin/nexus3 Sonatype Nexus3 Milestone7 docker image 2 [OK] home1oss/nexus3 An auto configured nexus3 2 [OK] Fxinnovation/nexus3 Sonatype Nexus3 in a container 1 [OK] flavioaiello/nexus3 Production ready lightweight Nexus3 with API … 1 [OK] cirepo/nexus3 An auto configured nexus3 1 [OK] alvindaiyan/nexus3-azure-appservice 1 Dwolla/nexus3-crowd Nexus3 with nexus3-crowd-plugin installed 0 [OK] joshdvir/nexus3 nexus3 0 [OK] freckleiot/nexus3-oss A Sonatype Nexus3 OSS image which makes it e... 0 [OK] sdase/nexus3-base-image An opinionated nexus3 docker image, based on... 0 [OK] fgbulsoni/nexus3 My fork of the Sonatype/Nexus3 image, with a... 0 stocksoftware/nexus3 A nexus3 docker instance 0 [OK] lokkju/nexus3-github-auth Sonatype Nexus 3 with Github authentication … 0 [OK] salte/nexus3 Extends the Sonatype nexus3 Docker image by... 0 [OK] azaa1/nexus3 Sonyatype Nexus Repository Manager 3 0 desiato/nexus3-ssl Sonatype Nexus 3 with SSL/TLS support. 0 [OK] mritd/nexus3 nexus3 0 [OK] jullyannem/nexus3 Custom image for sonatype/nexus3 0 Bigseasre/nexus3 mirror of the original nexus3 dockerfile 0 darthhater/nexus3 A series of example Dockerfiles and images f... 0 [OK] nasajon/nexus3 Nexus3 0 [OK] enieuw/nexus3-oss nexus3-oss 0 [OK] amribrahim00/nexus3 0
Pull nexus3 image
Docker pull docker.io/sonatype/nexus3
Console output
[root@xxx ~] # docker pull docker.io/sonatype/nexus3Using default tag: latestlatest: Pulling from sonatype/nexus3c65691897a4d: Pull complete 641d7cc5cbc4: Pull complete c508b13320cd: Pull complete 79e3bf9d3132: Pull complete Digest: sha256:2c33632ccd1f8c5f9023a3d7f5f541e211831e402219f8c5a83a29d1721457caStatus: Downloaded newer image for sonatype/nexus3:latestdocker.io/sonatype/nexus3:latest
View Mirror
Docker images
Console output
[root@xxx ~] # docker imagesREPOSITORY TAG IMAGE ID CREATED SIZEsonatype/nexus3 latest 8eb898be2a53 2 weeks ago 611MB
4. Run the nexus container
Docker run-id-- privileged=true-- name=nexus3-- restart=always-p 8081 purl 8081-v / wandou/nexus3/nexus-data:/var/nexus-data sonatype/nexus3
Console output
[root@xxx] # docker run-id-- privileged=true-- name=nexus3-- restart=always-p 8081 purl 8081-v / wandou/nexus3/nexus-data:/var/nexus-data sonatype/nexus3980f3759783f3ba7e59302848f816e371b229957f2c12b8f92934d468e061b00
Explanation:-id creates guardian container-privileged=true grants root permission (mounting multi-level directory must be true, otherwise the container has insufficient access to host)-name= name gives your container a name-p host port: container port mapping-v host directory: container directory mount here it takes some time to start and access nexus depending on the machine configuration. To access nexus3, please make sure that the 8081 port of the server (depending on the port configured when running the nexus container above) is open in the security group! Browsers visit http://ip:8081 6. After logging into the nexus3 page, there is a login button in the upper right corner that clicks to show the login box nexus3. The default account number is still admin, but the password has changed. The specific password is stored in the admin.password file in the nexus-data path of the nexus3 container: 1. View nexus3 Container id
Docker ps
Console display
[root@ecs-s6-xlarge-2-linux-20190927141629 ~] # docker psCONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES980f3759783f sonatype/nexus3 "sh-c ${SONATYPE_DI …" 4 minutes ago Up 4 minutes 0.0.0.08081/tcp nexus3 8081-> 8081/tcp nexus3
Write down CONTAINER ID:980f3759783f 2. Enter the container console
Docker exec-it 980f3759783f bash
Console display
[root@ecs-s6-xlarge-2-linux-20190927141629 ~] # docker exec-it 980f3759783f bashbash-4.4$ lsbin etc lib lost+found nexus-data root srv uid_entrypoint.sh varboot help.1 lib64 media opt run sys uid_template.shdev home licenses mnt proc sbin tmp usr
3. Enter the nexus-data folder
Bash-4.4$ cd nexus-data/bash-4.4$ lsadmin.password db generated-bundles karaf.pid log restore-from-backupblobs elasticsearch instances keystores orient tmpcache etc javaprefs lock port
4. Open the admin.password file
Bash-4.4$ vi admin.password
The first line is the password. Copy the password and log in with the admin account. After logging in, the system will automatically prompt you to change the admin password.
After reading the above, have you mastered how to install nexus3 in Docker? If you want to learn more skills or want to know more about it, you are welcome to follow the industry information channel, thank you for reading!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.