Update repository

Signed-off-by: Kang Huaishuai <khs1994@khs1994.com>
pull/485/head
Kang Huaishuai 2021-03-12 00:12:47 +08:00
parent bc43b30964
commit aa08e32003
No known key found for this signature in database
GPG Key ID: 5E515022F565DA09
3 changed files with 44 additions and 21 deletions

View File

@ -21,11 +21,11 @@
```bash ```bash
$ docker search centos $ docker search centos
NAME DESCRIPTION STARS OFFICIAL AUTOMATED NAME DESCRIPTION STARS OFFICIAL AUTOMATED
centos The official build of CentOS. 465 [OK] centos The official build of CentOS. 6449 [OK]
tianon/centos CentOS 5 and 6, created using rinse instea... 28 ansible/centos7-ansible Ansible on Centos7 132 [OK]
blalor/centos Bare-bones base CentOS 6.5 image 6 [OK] consol/centos-xfce-vnc Centos container with "headless" VNC session 126 [OK]
saltstack/centos-6-minimal 6 [OK] jdeathe/centos-ssh OpenSSH / Supervisor / EPEL/IUS/SCL Repos - 117 [OK]
tutum/centos-6.4 DEPRECATED. Use tutum/centos:6.4 instead. ... 5 [OK] centos/systemd systemd enabled base container. 96 [OK]
``` ```
`OFFICIAL` `AUTOMATED` `OFFICIAL` `AUTOMATED`
@ -34,7 +34,7 @@ tutum/centos-6.4 DEPRECATED. Use tutum/centos:6.4
`centos` Docker 使 `centos` Docker 使
`tianon/centos` Docker Hub `username/` 使 tianon `ansible/centos7-ansible` Docker Hub `username/` 使 ansible
`--filter=stars=N` `N` `--filter=stars=N` `N`

View File

@ -1,6 +1,6 @@
# Nexus3.x # Nexus3.x
使 Docker Registry Registry Nexus `Nexus3.x` Docker 使 [`Nexus3.x`](https://www.sonatype.com/nexus/repository-oss-download) 一个软件来管理 `Docker` , `Maven` , `Yum` , `PyPI` 等是一个明智的选择。 使 Docker Registry Registry `Nexus` `Nexus3.x` Docker 使 [`Nexus3.x`](https://www.sonatype.com/nexus/repository-oss-download) 一个软件来管理 `Docker` , `Maven` , `Yum` , `PyPI` 等是一个明智的选择。
## Nexus ## Nexus
@ -11,20 +11,43 @@ $ docker run -d --name nexus3 --restart=always \
sonatype/nexus3 sonatype/nexus3
``` ```
3-5 `nexus3` 退使 `http://YourIP:8081` 访 Nexus 3-5 使 `docker logs nexus3 -f`
Nexus `admin` `admin123` 齿 ```bash
$ docker logs nexus3 -f
2021-03-11 15:31:21,990+0000 INFO [jetty-main-1] *SYSTEM org.sonatype.nexus.bootstrap.jetty.JettyServer -
-------------------------------------------------
Started Sonatype Nexus OSS 3.30.0-01
-------------------------------------------------
```
`Nexus` 使 `http://YourIP:8081` 访 `Nexus`
```bash
$ docker exec nexus3 cat /nexus-data/admin.password
9266139e-41a2-4abb-92ec-e4142a3532cb
```
Nexus `admin`
齿
## ##
`Repository->Repositories` `Create repository` `docker (hosted)` `Repository->Repositories` `Create repository` `docker (hosted)`
* Name: * **Name**:
* HTTP: 访 * **HTTP**: 访**5001**
* Enable Docker V1 API: V1 * **Hosted -> Deployment pollcy**: **Allow redeploy** Docker
* Hosted -> Deployment pollcy: Allow redeploy Docker
docker (proxy) DockerHub docker (group) hosted proxy 访 DockerHub Nexus `docker (proxy)` DockerHub `docker (group)` `hosted` `proxy` 访 DockerHub Nexus
## 访 ## 访
@ -43,7 +66,7 @@ NGINX 示例配置如下
```nginx ```nginx
upstream register upstream register
{ {
server "YourHostName OR IP":5001; # HTTP server "YourHostName OR IP":5001; # HTTP
check interval=3000 rise=2 fall=10 timeout=1000 type=http; check interval=3000 rise=2 fall=10 timeout=1000 type=http;
check_http_send "HEAD / HTTP/1.0\r\n\r\n"; check_http_send "HEAD / HTTP/1.0\r\n\r\n";
check_http_expect_alive http_4xx; check_http_expect_alive http_4xx;
@ -91,9 +114,9 @@ server {
## Docker 访 ## Docker 访
SSL Docker Docker SSL [](./registry.md) https Docker Docker
使 SSL 访访 使 SSL 访
```bash ```bash
$ openssl s_client -showcerts -connect YourDomainName OR HostIP:443 </dev/null 2>/dev/null|openssl x509 -outform PEM >ca.crt $ openssl s_client -showcerts -connect YourDomainName OR HostIP:443 </dev/null 2>/dev/null|openssl x509 -outform PEM >ca.crt
@ -101,4 +124,4 @@ $ cat ca.crt | sudo tee -a /etc/ssl/certs/ca-certificates.crt
$ systemctl restart docker $ systemctl restart docker
``` ```
使 `docker login YourDomainName OR HostIP` Nexus 使 `docker login YourDomainName OR HostIP` Nexus

View File

@ -10,7 +10,7 @@
### ###
`registry` 使 `registry`
```bash ```bash
$ docker run -d -p 5000:5000 --restart=always --name registry registry $ docker run -d -p 5000:5000 --restart=always --name registry registry
@ -91,7 +91,7 @@ REPOSITORY TAG IMAGE ID CREAT
127.0.0.1:5000/ubuntu:latest latest ba5877dc9bec 6 weeks ago 192.7 MB 127.0.0.1:5000/ubuntu:latest latest ba5877dc9bec 6 weeks ago 192.7 MB
``` ```
## ## https
使 `127.0.0.1:5000` `192.168.199.100:5000` 使 `127.0.0.1:5000` `192.168.199.100:5000`