: :
Previous slide
Next slide

Unifi Let’s Encrypt SSL with API keys

There is a new method for using Let’s Encrypt SSL certificates on Unifi Network and Unifi Cloud Keys (Gen 1 / Gen 2) while using an API key instead of HTTPS verification. This method is for Cloudflare but should be able to be adapted for other DNS hosts.

CFZONEID = Your Cloudflare Zone ID located on the domain overview page at the bottom right.
CFAPITOKEN = Your Cloudflare API token for the zone.
YOURUNIFIFQDN = The fully qualified domain name of your Unifi controller. It must end in the domain name of your CFZONEID. An example would be unifi.example.com

curl https://get.acme.sh | sh -s [email protected]
export CF_Zone_ID=”CFZONEID”
export CF_Token=”CFAPITOKEN”
/root/.acme.sh/acme.sh –set-default-ca –server letsencrypt
/root/.acme.sh/acme.sh –issue –dns dns_cf -d YOURUNIFIFQDN
/root/.acme.sh/acme.sh –deploy -d YOURUNIFIFQDN –deploy-hook unifi
crontab -l

https://gist.github.com/blackjack4494/331e46678c0ea15a61c4cc6756c21969

Facebook
Twitter
LinkedIn

Leave a Reply

Your email address will not be published. Required fields are marked *