update https docs

This commit is contained in:
Henry Zhang 2016-03-31 12:12:58 +08:00
parent d05d9d7088
commit c64e1d683a

View File

@ -58,10 +58,10 @@ Edit the file nginx.conf and replace two occurrences of **harbordomain.com** to
... ...
server { server {
listen 80; listen 80;
server_name harbordomain.com; server_name harbordomain.com;
rewrite ^/(.*) https://$server_name$1 permanent; rewrite ^/(.*) https://$server_name$1 permanent;
``` ```
Then look for the SSL section to make sure the files of your certificates match the names in the config file. Do not change the path of the files. Then look for the SSL section to make sure the files of your certificates match the names in the config file. Do not change the path of the files.
``` ```
@ -109,12 +109,13 @@ After setting up HTTPS for Harbor, you can verify it by the follow steps:
cat intermediate-certificate.pem >> yourdomain.com.crt cat intermediate-certificate.pem >> yourdomain.com.crt
``` ```
2. On some systems where docker daemon runs, you may need to trust the certificate at OS level. 2. On some systems where docker daemon runs, you may need to trust the certificate at OS level.
On Ubuntu, this can be done by below commands: On Ubuntu, this can be done by below commands:
```sh ```sh
cp youdomain.com.crt /usr/local/share/ca-certificates/reg.yourdomain.com.crt cp youdomain.com.crt /usr/local/share/ca-certificates/reg.yourdomain.com.crt
update-ca-certificates update-ca-certificates
``` ```
On Red Hat (CentOS etc), the commands are:
On Red Hat (CentOS etc), the commands are:
```sh ```sh
cp yourdomain.com.crt /etc/pki/ca-trust/source/anchors/reg.yourdomain.com.crt cp yourdomain.com.crt /etc/pki/ca-trust/source/anchors/reg.yourdomain.com.crt
update-ca-trust update-ca-trust