1. 创建目录

    1. mkdir data
    2. cd data
    3. mkdir nexus-data
    4. # 设置文件夹权限
    5. chmod 777 /data/nexus-data
  2. 拉取镜像

    1. podman pull docker.io/sonatype/nexus3
  3. 运行

    1. podman run --net=host --privileged=true -p 8081-8089:8081-8089 --name nexus -v /data/nexus-data:/nexus-data docker.io/sonatype/nexus3

    ```shell

    设置端口转发

    netsh interface portproxy add v4tov4 listenport=8081 listenaddress=0.0.0.0 connectport=8081 connectaddress=172.26.243.0 protocol=tcp

netsh interface portproxy add v4tov4 listenport=8153 listenaddress=0.0.0.0 connectport=8153 connectaddress=172.26.243.0 protocol=tcp

查看端口转发

netsh interface portproxy show all

删除端口转发

netsh interface portproxy delete v4tov4 listenport=8081 listenaddress=0.0.0.0 ``` 管理员密码在:/data/nexus-data 下

参考 :https://blog.csdn.net/shi_hong_fei_hei/article/details/115049919?utm_source=app&app_version=4.16.0&code=app_1562916241&uLinkId=usr1mkqgl919blen