If your domain is already on Cloudflare with proxy enabled, generate an Origin Certificate in the Cloudflare dashboard (SSL/TLS → Origin Server) and use the ready-to-use config shipped with the repo at nginx/host-proxy.conf:
sudo cp nginx/host-proxy.conf /etc/nginx/sites-available/resolvd
# Drop your origin cert + key into /etc/nginx/cloudflare/
sudo ln -s /etc/nginx/sites-available/resolvd /etc/nginx/sites-enabled/
sudo nginx -t && sudo systemctl reload nginx
Set Cloudflare SSL/TLS mode to Full (strict).