-
1.2 Stable
released this
2025-10-05 20:11:01 +00:00 | 3 commits to main since this releaseRelease Notes / Commit Message
Improvements:
Enhanced error handling and script robustness:
-
Added set -euo pipefail for stricter error handling and detection of undefined variables and pipeline failures.
-
Validates presence of required CLI tools (curl and jq) before execution.
-
Checks for the presence of .env files before processing to avoid errors if none are found.
-
Validates Mullvad API JSON response more robustly to detect missing or invalid IP information.
Improved environment variable management:
-
Switched from sourcing DNS_RECORD_ID to dynamically fetching the DNS record ID via Cloudflare API based on DNS_NAME.
-
Clearly logs missing required environment variables per .env file, specifying exactly which are missing.
Cloudflare API usage improvements:
-
Updated DNS record creation with POST request including correct headers (X-Auth-Email and X-Auth-Key).
-
Changed DNS record updates to use PATCH method instead of PUT, as per Cloudflare best practices.
-
Added support to create DNS records if they do not already exist, improving automation and flexibility.
-
Uses JSON data strings consistently and safely with proper quoting.
Logging enhancements:
-
Improved log messages for clarity on each step, including when no updates are needed.
-
Logs Cloudflare API responses on failure for easier debugging.
Downloads
-