准备工作
```sh
安装docker
安装docker-compose
```
安装harbor
```sh
$ wget https://github.com/goharbor/harbor/releases/download/v2.3.0/harbor-offline-installer-v2.3.0.tgz
$ tar xvf harbor-offline-installer-v2.3.0.tgz
$ mv harbor /opt/
$ cd /opt/harbor
$ mv harbor.yml.tmpl harbor.yml
...
hostname: harbor.example.com
http:
port: 80
https:
port: 443
certificate: /opt/harbor/ssl/5024509__example.com.pem
private_key: /opt/harbor/ssl/5024509__example.com.key
harbor_admin_password: Harbor12345
...
$ ./install.sh --with-chartmuseum #安装harbor,包括chart
```
关闭harbor
```sh
$ cd /opt/harbor
$ docker-compose down
```
启动harbor
```sh
$ cd /opt/harbor
$ docker-compose up -d
```