共计 822 个字符,预计需要花费 3 分钟才能阅读完成。

证书可以自签或申请免费证书,若使用阿里云免费证书,每个账户只有10个,步骤略
证书路径/etc/gitlab/ssl
[root@ks-gitlab ~]# ll /etc/gitlab/ssl/
总用量 16
-rw-r--r-- 1 600 root 1679 8月 20 17:54 server.key
-rw-r--r-- 1 600 root 3863 8月 20 17:54 server.pem
-rw-r--r-- 1 600 root 4160 8月 20 17:55 通配符证书ttttt.cn_nginx.zip
配置gitlab配置文件
[root@ks-gitlab ~]# ll /etc/gitlab/
总用量 132
-rw------- 1 root root 110924 10月 21 15:54 gitlab.rb
-rw------- 1 root root 18888 10月 21 15:54 gitlab-secrets.json
drwxr-xr-x 2 root root 84 10月 21 15:22 ssl
drwxr-xr-x 2 root root 6 9月 11 18:53 trusted-certs
[root@ks-gitlab ~]# vim /etc/gitlab/gitlab.rb
..........
nginx['redirect_http_to_https'] = true
#nginx['ssl_certificate'] = "/etc/gitlab/ssl/#{node['fqdn']}.crt"
nginx['ssl_certificate'] = "/etc/gitlab/ssl/server.pem"
#nginx['ssl_certificate_key'] = "/etc/gitlab/ssl/#{node['fqdn']}.key"
nginx['ssl_certificate_key'] = "/etc/gitlab/ssl/server.key"
..........
重新生成配置
gitlab-ctl reconfigure
正文完
隐私政策
留言板
金色传说
kubernetes
terraform
云生原
helm
代码编程
Java
Python
Shell
DevOps
Ansible
Gitlab
Jenkins
运维
老司机
Linux 杂锦
Nginx
数据库
elasticsearch
监控
上帝视角
DJI FPV
DJI mini 3 pro
关于本站