nginx acme自动续期

Last updated on February 21, 2025 am

🧙 Questions

使用acme.sh自动续期

☄️ Ideas

acme.sh安装
cd /tmp
git clone https://gitee.com/ispong/acme.sh.git
cd /tmp/acme.sh
./acme.sh --install -m ispong@outlook.com
source /root/.acme.sh/acme.sh.env
acme.sh -v
rm -rf /tmp/acme.sh
常用命令

要给nginx提前配置路径

mkdir -p /var/www/html
vim /etc/nginx/nginx.conf
location /.well-known/acme-challenge/ {
    root /var/www/html;
}
acme.sh --set-default-ca --server letsencrypt
acme.sh --issue -d zhihuiyun-demo.isxcode.com -w /var/www/html
acme.sh --list
# 查看定时器
cat /var/spool/cron/root
重新指向路径
acme.sh --install-cert -d zhihuiyun-demo.isxcode.com \
--key-file       /data/nginx/ssl/zhihuiyun-demo.isxcode.com.key \
--fullchain-file /data/nginx/ssl/zhihuiyun-demo.isxcode.com.pem \
--reloadcmd     "nginx -s reload"
删除许可证
acme.sh --list
# acme.sh --remove -d zhiliuyun.isxcode.com

nginx acme自动续期
https://ispong.isxcode.com/vue/nginx/nginx acme自动续期/
Author
ispong
Posted on
February 8, 2025
Licensed under