Deploy Natali Proxy Worker #3
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Fix Cloudflare SSL Mode | |
| on: | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| jobs: | |
| fix-ssl: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check & Fix SSL Mode | |
| env: | |
| CF_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }} | |
| run: | | |
| set -x | |
| ZONE_ID="5b3f8237bfa2518bff375eb8163623a5" | |
| echo "=== SSL setting ===" | |
| curl -s -H "Authorization: Bearer $CF_API_TOKEN" \ | |
| "https://api.cloudflare.com/client/v4/zones/$ZONE_ID/settings/ssl" | jq . | |
| echo "=== Always Use HTTPS ===" | |
| curl -s -H "Authorization: Bearer $CF_API_TOKEN" \ | |
| "https://api.cloudflare.com/client/v4/zones/$ZONE_ID/settings/always_use_https" | jq . | |
| echo "=== Min TLS Version ===" | |
| curl -s -H "Authorization: Bearer $CF_API_TOKEN" \ | |
| "https://api.cloudflare.com/client/v4/zones/$ZONE_ID/settings/min_tls_version" | jq . | |
| echo "=== Automatic HTTPS Rewrites ===" | |
| curl -s -H "Authorization: Bearer $CF_API_TOKEN" \ | |
| "https://api.cloudflare.com/client/v4/zones/$ZONE_ID/settings/automatic_https_rewrites" | jq . | |
| echo "=== Opportunistic Encryption ===" | |
| curl -s -H "Authorization: Bearer $CF_API_TOKEN" \ | |
| "https://api.cloudflare.com/client/v4/zones/$ZONE_ID/settings/opportunistic_encryption" | jq . |