Cloudflare for a site
Have a site's DNS records written for you and set SSL for its domains in a connected Cloudflare zone.
On this page
Before you start
- You can open the site in Managed Websites. Anyone who can open a site can use its Cloudflare zone.
- Your organisation's Cloudflare account is connected: see Connect Cloudflare.
- The site's domain is in a zone that connection can see.
What the connection adds to a site
| Where | What you get |
|---|---|
| Hostnames | A hostname in a connected zone reads Proxied by Cloudflare and names the zone. |
| Attaching a domain, Change primary URL | Point DNS for me writes one proxied A record for each hostname, so you copy no records. |
| Domains & HTTPS | Advice when the zone's SSL/TLS mode would stop the site working, and the Per-domain SSL card. |
| The platform's section | Purge Cloudflare cache, for the whole zone or up to 30 addresses. |
Have the DNS records written
Tick Point DNS for me
At the DNS check of Add a domain, tick Point DNS for me. Each hostname reads Will be pointed.
Confirm
Finish the dialog. The records are written in the connected zone and checked again.
Tick Replace the existing records when a hostname already points somewhere else.
Set SSL for chosen domains
The zone's SSL/TLS mode should be Full while a certificate is issued, then Full (strict). With Flexible, visitors are sent round in a loop.
Open Per-domain SSL
In Domains & HTTPS, find Per-domain SSL. It sets SSL for the domains you choose with a Cloudflare rule; every other name in the zone keeps the zone's own mode.
Add a rule
Under Add a rule, tick the Domains, choose Full or Full (strict) under SSL, then choose Add rule. Check access asks Cloudflare whether your token may do this and changes nothing.
The rule's Status reads Waiting for Cloudflare, then Active. Remove… deletes the rule, and those domains use the zone's own mode again.
A rule needs one more permission on your Cloudflare token: Zone, Config Rules, Edit. A rule names up to 50 domains in one zone.
Automate this
auto lets the Control Panel find the zone for the site's domain, manual chooses one of the connection's zones by zone_id, and off stops using Cloudflare for the site.
curl -X PUT https://manage.corefinity.com/api/corestack/sites/1042/cloudflare-zone \
-H "Authorization: Bearer $COREFINITY_TOKEN" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{
"mode": "auto"
}'Your assistant calls corestack_site_cloudflare_zone_set.
{
"name": "corestack_site_cloudflare_zone_set",
"arguments": {
"site_id": 4211,
"mode": "auto"
}
}