after upgrade lxd to 4.0 I am getting.
Error: Get https://10.10.10.2:8443/1.0: x509: certificate is valid for 127.0.0.1, ::1, not 10.10.10.2
I found that new server.crt and server.key was generated in /var/snap/lxd/common/lxd but without IP address of that lxd server.
How can I regenerate this certificate to include server IP address?
Fixed by remove server and add again.
lxd remote remove “server”
lxd remote add “server”