Deploy your DNS configuration using GitHub Actions using DNSControl.
Go to file
2019-08-11 14:09:03 +02:00
.github Add migrated GitHub workflow 2019-08-11 14:09:03 +02:00
examples Added examples README. 2019-01-05 16:18:17 +01:00
test Added tests for entrypoint script. 2019-01-28 21:12:34 +01:00
Dockerfile Upgrade dnscontrol v2.9 2019-05-28 09:48:22 +02:00
entrypoint.sh Added tests for entrypoint script. 2019-01-28 21:12:34 +01:00
LICENSE.txt First commit. 2019-01-05 12:24:28 +01:00
README.md Updated README. 2019-01-05 15:12:33 +01:00

DNSControl Action

Deploy your DNS configuration using GitHub Actions using DNSControl.

Usage

These are the three relevant sub commands to use with this action.

check

Run the action with the 'check' argument in order to check and validate the dnscontrol.js file. This action does not communicate with the DNS providers, hence does not require any secrets to be set.

action "DNSControl check" {
  uses = "koenrh/dnscontrol-action@master"
  args = "check"
}

preview

Run the action with the 'preview' argument to check what changes need to be made. It prints out what DNS records are expected to be created, modified or deleted. This action requires the secrets for the specified DNS providers.

action "DNSControl preview" {
  uses = "koenrh/dnscontrol-action@master"
  args = "preview"
  secrets = ["CLOUDFLARE_API_USER", "CLOUDFLARE_API_KEY"]
}

This is the action you probably want to run for each branch so that proposed changes could be verified before an authorized person merges these changes into master.

push

Run the action with the 'push' arugment to publish the changes to the specified DNS providers.

Running the action with the 'push' argument will publish the changes with the specified DNS providers. You should probably only use this command combined with the GitHub Filters action to make sure that only changes in the master branch are deployed to production.

action "DNSControl push" {
  uses = "koenrh/dnscontrol-action@master"
  args = "push"
  secrets = ["CLOUDFLARE_API_KEY", "CLOUDFLARE_API_USER"]
}

You should probably only use this command combined with the GitHub Filters action to make sure that only changes in the master branch are deployed to production.

Secrets

Depending on the DNS providers that are used, this action requires secrets to be set.

Cloudflare

Documentation

  • CLOUDFLARE_API_USER
  • CLOUDFLARE_API_KEY
  • CLOUDFLARE_ACCOUNT_ID (optional)
  • CLOUDFLARE_ACCOUNT_NAME (optional)

DigitalOcean

Documentation

  • DIGITALOCEAN_OAUTH_TOKEN

DNSimple

Documentation

  • DNSIMPLE_ACCOUNT_ACCESS_TOKEN

Gandi

Documentation

  • GANDI_API_KEY

Google CLOUD DNS

Documentation

  • GOOGLE_CLOUD_PROJECT_ID
  • GOOGLE_CLOUD_PRIVATE_KEY_ID
  • GOOGLE_CLOUD_PRIVATE_KEY
  • GOOGLE_CLOUD_CLIENT_EMAIL
  • GOOGLE_CLOUD_CLIENT_ID
  • GOOGLE_CLOUD_CLIENT_X509_CERT_URL

Linode

Documentation

  • LINODE_ACCESS_TOKEN

Name.com

Documentation

  • NAME_COM_API_USER
  • NAME_COM_API_KEY
  • NAME_COM_API_URL (optional)

Namecheap

Documentation

  • NAMECHEAP_API_USER
  • NAMECHEAP_API_KEY
  • NAMECHEAP_BASE_URL (optional)

NS1

Documentation

  • NSONE_API_KEY

OVH

Documentation

  • OVH_APP_KEY
  • OVH_APP_SECRET_KEY
  • OVH_CONSUMER_KEY

Amazon Route 53

Documentation

  • AWS_ACCESS_KEY_ID
  • AWS_SECRET_ACCESS_KEY
  • AWS_SESSION_TOKEN (optional)

SoftLayer

Documentation

  • SOFTLAYER_USERNAME
  • SOFTLAYER_API_KEY

Vultr

Documentation

  • VULTR_TOKEN