大网数据广告活动
服务器运维问答

Migrating certbot/letsencrypt certificate to new server

· 52CE 我爱测

I have a server out there that supports HTTPS using a certbot/letsencrypt certificate. I am doing a general software upgrade so to minimize risks and downtime, I'm installing new releases on a new server on which I import the liv…

问题原文

原帖链接 · xenoid · CC BY-SA 4.0

I have a server out there that supports HTTPS using a certbot/letsencrypt certificate.

I am doing a general software upgrade so to minimize risks and downtime, I'm installing new releases on a new server on which I import the live server data for tests. When everything works I'll have the DNS record changed to point to the new server.

My question is what should I do for the certificate? Can I just copy over the existing one and let it get renewed when necessary? Or will the certificate be incompatible and/or LE will complain that the address has changed during the auto-renewal process? Will LE be sensitive to reverse DNS (it may take some more delay for the reverse DNS to work). Is there any other problem I didn't think about?

已采纳解答

原帖链接 · Stefano Martins · CC BY-SA 4.0

By default, Certbot/Letsencrypt stores their configuration files and generated certificates in /etc/letsencrypt. So you just need to install Certbot into the new server and copy the directory from the old one. Of course you're gonna have to configure the webserver (Apache, Nginx, whatever you're using), pointing to the certificates in the new server.

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2020-01-13)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 4.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。