Problem while setting up HTTPS

There is now Caddy v2. So I assume this installation script is for version 1 and version 2 has different installing workflow. I will need to see what is different, then update the guide.