最新5步完成acme.sh域名证书生成

1、yum install socat -y                                                                                         #安装组件
2、curl https://get.acme.sh | sh -s email=xxxxx@126.com                                 #安装acme

[2024年 09月 27日 星期五 08:42:56 CST] Installing from online archive.
[2024年 09月 27日 星期五 08:42:56 CST] Downloading https://github.com/acmesh-official/acme.sh/archive/master.tar.gz
[2024年 09月 27日 星期五 08:42:58 CST] Extracting master.tar.gz
[2024年 09月 27日 星期五 08:42:58 CST] It is recommended to install socat first.
[2024年 09月 27日 星期五 08:42:58 CST] We use socat for the standalone server, which is used for standalone mode.
[2024年 09月 27日 星期五 08:42:58 CST] If you don't want to use standalone mode, you may ignore this warning.
[2024年 09月 27日 星期五 08:42:58 CST] Installing to /root/.acme.sh
[2024年 09月 27日 星期五 08:42:58 CST] Installed to /root/.acme.sh/acme.sh
[2024年 09月 27日 星期五 08:42:58 CST] Installing alias to '/root/.bashrc'
[2024年 09月 27日 星期五 08:42:58 CST] Close and reopen your terminal to start using acme.sh
[2024年 09月 27日 星期五 08:42:58 CST] Installing alias to '/root/.cshrc'
[2024年 09月 27日 星期五 08:42:58 CST] Installing alias to '/root/.tcshrc'
[2024年 09月 27日 星期五 08:42:58 CST] Installing cron job
[2024年 09月 27日 星期五 08:42:58 CST] bash has been found. Changing the shebang to use bash as preferred.
[2024年 09月 27日 星期五 08:43:00 CST] OK
[2024年 09月 27日 星期五 08:43:00 CST] Install success

3、退出终端,重新进入以华为云为例:需开通授权用户名

export HUAWEICLOUD_Username="xxxxx"
export HUAWEICLOUD_Password="xxxx"
export HUAWEICLOUD_DomainName="xxxx.com"

4、生成证书

acme.sh --issue --dns dns_huaweicloud -d xxxx.com -d *.xxxx.com 

acme.sh --renew  -d xxxx.com -d *.xxxx.com     --force                                  #强制重新生成证书(确保txt记录和HUAWEICLOUD环境变量--先配置,正常后,多试几次)


5、查看证书

acme.sh --info -d xxxx.com    

acme.sh --uninstall                                                                                  #卸载
acme.sh --list                                                                                           #查看生成证书
--webroot /var/www/yourdomain                                                              #指定目录    

--------------------------------------------------------------------------------------------------------------------------------

可以参考证书:

泗阳Linux系统管理

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值