sudo apt install -y debian-keyring debian-archive-keyring apt-transport-https
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/gpg.key' | sudo apt-key add - 
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/debian.deb.txt' | sudo tee -a /etc/apt/sources.list.d/caddy-stable.list
    sudo apt update
    sudo apt install caddy

证书位置

   cd /var/lib/caddy/.local/share/caddy/certificates/acme-v02.api.letsencrypt.org-directory/

配置文件路径

/etc/caddy/Caddyfile

修改配置后 重新加载配置

反向代理

www.psvmc.cn {
    reverse_proxy localhost:9000
}

修改配置后 重新加载配置

systemctl reload caddy

Ubuntu
sudo systemctl restart caddy

标签: none

添加新评论