
DirectAdmin 域名或ip使用SSL访问的方法
默认的DirectAdmin 是不支持SSL链接的,下面是配置方法
首先编译letsencrypt
1
2
3
4
5
cd /usr/local/directadmin/custombuild
./build rewrite_confs
./build update
./build letsencrypt
1
2
3
echo "letsencrypt=1" >> /usr/local/directadmin/conf/directadmin.conf
//开启letsencrypt
1
2
3
cd /usr/local/directadmin/scripts
./letsencrypt.sh request_single hostname.yourdomain.com 4096
输入你的域名,后面的是证书位数可以是2048,也可以说4096
域名先做ip指向,否则会申请证书失败。
1
2
3
service directadmin restart
service httpd restart
//重启相关进程
重点如果使用域名访问,切忌要关闭cdn或者说直接绕过,不缓存任何数据
现在使用域名或ip ssl访问DirectAdmin 即可~