File tree Expand file tree Collapse file tree 2 files changed +24
-4
lines changed
Expand file tree Collapse file tree 2 files changed +24
-4
lines changed Original file line number Diff line number Diff line change 11on :
22 workflow_dispatch :
3+ push :
4+ branches : [ website ]
35 schedule :
4- - cron : ' 0 * * * *'
6+ - cron : 0 0 * * *
57
6- name : update badges
8+ name : deploy updated script/data for badges
79jobs :
8- update_badges :
10+ deploy_badges :
911 runs-on : ubuntu-20.04
1012 steps :
1113 - uses : actions/checkout@v2
12- - name : update badges
14+ - name : deploy updated script/data for badges
1315 env :
1416 CLOUDFLARE_API_TOKEN : ${{ secrets.CLOUDFLARE_API_TOKEN }}
1517 CLOUDFLARE_ACCOUNT_ID : ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
Original file line number Diff line number Diff line change @@ -22,3 +22,21 @@ NOTE: two worker scripts are created (`user-badge`) and (`org-badge`) with diffe
22224 . Configure each of the worker scripts [ as described here] ( https://developers.cloudflare.com/workers/platform/routes#custom-routes ) :
2323 * Create an AAAA record for ` 100:: ` which is proxied by CloudFlare (orange-cloud)
2424 * Ensure that a route is added which maps to the worker, as no routes are added by default
25+
26+ NOTE: I use [ DNSControl] ( https://stackexchange.github.io/dnscontrol/ ) for managing DNS, and this is the configuration I use:
27+
28+ ``` js
29+ var REGISTRAR = NewRegistrar (' none' , ' NONE' );
30+ var CLOUDFLARE = NewDnsProvider (' cloudflare' , ' CLOUDFLAREAPI' , { manage_workers: true });
31+
32+ D (' committers.top' , REGISTRAR , DnsProvider (CLOUDFLARE ),
33+ ALIAS (' @' , ' ashkulz.github.io.' ),
34+ CNAME (' www' , ' ashkulz.github.io.' ),
35+ AAAA (' user-badge' , ' 100::' , CF_PROXY_ON ),
36+ AAAA (' org-badge' , ' 100::' , CF_PROXY_ON ),
37+
38+ CF_WORKER_ROUTE (" user-badge.committers.top/*" , " user-badge" ),
39+ CF_WORKER_ROUTE (" org-badge.committers.top/*" , " org-badge" )
40+ )
41+
42+ ```
You can’t perform that action at this time.
0 commit comments