For a detailed explanation of acme.sh
, you can refer to [here][1].
Since my nginx configuration file is very messy, I chose to turn off nginx and let acme.sh act as the server to verify.
First, you need to install socat.
apt install socat
Then
acme.sh --issue -d zhufn.fun --standalone
The generated certificate will automatically be placed in the nginx folder, quite magical.
![ ][2]
Later, I found out that one certificate can correspond to multiple domain names.
So
acme.sh --issue -d zhufn.fun -d rss.zhufn.fun -d tb.zhufn.fun -d i.zhufn.fun --standalone
Then just adjust the paths in nginx, and you can use one certificate for all.
[1]: https://github.com/acmesh-official/acme.sh/wiki/Explanation
[2]: https://s2.ax1x.com/2020/02/03/1aCQkF.png