Giter Club home page Giter Club logo

dnslink-cloudflare's Introduction

dnslink-cloudflare

Update dnslink TXT records in Cloudflare

Usage

npx dnslink-cloudflare -d <domain> -l <link> [-r record]

Environment variables

It can be done two ways. The first is with email and API key.

  • CF_API_KEY CloudFlare API key
  • CF_API_EMAIL CloudFlare API email

The second is with just the API token (permissions: zone:read for all zones and dns:edit for specific zone):

CF_API_TOKEN CloudFlare API token

These values are obtained from in the CloudFlare account. https://dash.cloudflare.com/profile/api-tokens

Contributing

PRs accepted.

License

MIT © Protocol Labs

dnslink-cloudflare's People

Contributors

dependabot-preview[bot] avatar hacdias avatar sixcorners avatar tcrowe avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

dnslink-cloudflare's Issues

Required permissions arent properly notated

Right now, dnslink-cloudflare requires zone:read for all zones, and dns:edit for one specific zone

I cant remember the first permission being required in previous versions of this library, and the change resulted in me debugging crashing deployments (via ipfs-deploy), please describe (in the readme) which permissions are required for the API token, for the library to function.

Can't edit DNSlink TXT record created by Web3 Gateway.

I have web3 IPFS gateway subcription. when I create an IPFS gateway it will create DNS records as well (hostname and DNSLink), I can't update the DNSLink record.

Should I check the API token permisssion?
or
this binary does not have this funtionaly to edit DNSLink created by IPFS gateway?

Thanks

Paginate through records

If you have more than 20 records then this probably won't find the dnslink TXT record. This should perform pagination to check all records.

Can't change the txt record content by calling record's name

Hello! I could not find 1 example of the command

After creating the API token for read all zone and edit sepcific zone. I am receiving error HTTPError: Response code 403 (Forbidden)

Below is the command
CF_API_TOKEN="mytoken" npx dnslink-cloudflare -d myDomain -l fromlocal -r test

  • I own the domain which have a txt record with name test. I want to change the content of the test record to fromlocal through this binary, then I will put this command in the CI/CD pipeline.

Support cloudflare tokens

Support and document cloudflare auth tokens.

I think you probably need Zone > Zone > Read and Zone > DNS > Edit permissions FYI.
Also based on my testing you need to not restrict the token to one zone.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.