简体   繁体   中英

Sonatype Nexus3 docker image - How to setup an internal docker repository

Anyone had any experience setting this up? Https needs to be enabled in the sonatype/nexus3 config but the files are read only. How can this be edited without having to do a docker build using the nexus3 image? Can i login as root inside the container?

One of our internal people here at Sonatype created a Docker image that helps with this:

https://hub.docker.com/r/bradbeck/nexus-https/~/dockerfile/

This might help grease the skids for you. Of note this is not supported by Sonatype, but by Brad himself. Using this Dockerfile as your base would be good, as it will likely be fairly close to our supported one.

You'd likely modify this to expose a few more ports for the Docker registries you want to create. Thoughts are an internal hosted registry, a proxy of the hub, and then a group of the two for ease of access.

Run through most of the work here as well: https://books.sonatype.com/nexus-book/reference3/docker.html

$ docker run -d -p 8081:8081 Have you mapped the port with host and docker container.

You can login in container as

           ```docker exec -it $container_id /bin/bash```

You can try to use my solution , which actually doesn't modify sonatype/nexus3 original image, but instead use nginx-proxy (with ssl support) in front of nexus3 itself. In short it uses docker-compose to make nexus3+nginx work out of the box with one click. And at the same time I also have some API calls to make configuration changes during nexus3 deployment, you can extend them with your custom ones.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM