Initial Pantheon infrastructure

This commit is contained in:
2026-08-03 22:56:18 +10:00
commit afc9ee12f8
36 changed files with 4408 additions and 0 deletions
+27
View File
@@ -0,0 +1,27 @@
#!/usr/bin/env python3
import os
import requests
from dotenv import load_dotenv
load_dotenv()
TOKEN = os.getenv("CF_API_TOKEN")
ZONE = os.getenv("CF_ZONE_ID")
headers = {
"Authorization": f"Bearer {TOKEN}",
"Content-Type": "application/json",
}
url = f"https://api.cloudflare.com/client/v4/zones/{ZONE}/dns_records"
response = requests.get(url, headers=headers)
response.raise_for_status()
for record in response.json()["result"]:
print(
f"{record['type']:4} "
f"{record['name']:35} "
f"{record['content']}"
)