🚀
DNSControl
🚀
DNSControl
  • Introduction to DNSControl
  • Getting Started
    • Overview
    • Examples
    • Migrating zones to DNSControl
    • TypeScript autocomplete and type checking
  • Language Reference
    • JavaScript DSL
    • Top Level Functions
      • D
      • DEFAULTS
      • DOMAIN_ELSEWHERE
      • DOMAIN_ELSEWHERE_AUTO
      • D_EXTEND
      • FETCH
      • HASH
      • IP
      • NewDnsProvider
      • NewRegistrar
      • PANIC
      • REV
      • REVCOMPAT
      • getConfiguredDomains
      • require
      • require_glob
    • Domain Modifiers
      • A
      • AAAA
      • ALIAS
      • AUTODNSSEC_OFF
      • AUTODNSSEC_ON
      • CAA
      • CAA_BUILDER
      • CNAME
      • DHCID
      • DNAME
      • DNSKEY
      • DISABLE_IGNORE_SAFETY_CHECK
      • DMARC_BUILDER
      • DS
      • DefaultTTL
      • DnsProvider
      • FRAME
      • HTTPS
      • IGNORE
      • IGNORE_NAME
      • IGNORE_TARGET
      • IMPORT_TRANSFORM
      • IMPORT_TRANSFORM_STRIP
      • INCLUDE
      • LOC
      • LOC_BUILDER_DD
      • LOC_BUILDER_DMM_STR
      • LOC_BUILDER_DMS_STR
      • LOC_BUILDER_STR
      • M365_BUILDER
      • MX
      • NAMESERVER
      • NAMESERVER_TTL
      • NAPTR
      • NO_PURGE
      • NS
      • PTR
      • PURGE
      • SOA
      • SPF_BUILDER
      • SRV
      • SSHFP
      • SVCB
      • TLSA
      • TXT
      • URL
      • URL301
      • Service Provider specific
        • Akamai Edge Dns
          • AKAMAICDN
        • Amazon Route 53
          • R53_ALIAS
        • Azure DNS
          • AZURE_ALIAS
        • Cloudflare DNS
          • CF_REDIRECT
          • CF_SINGLE_REDIRECT
          • CF_TEMP_REDIRECT
          • CF_WORKER_ROUTE
        • ClouDNS
          • CLOUDNS_WR
    • Record Modifiers
      • TTL
      • Service Provider specific
        • Amazon Route 53
          • R53_ZONE
          • R53_EVALUATE_TARGET_HEALTH
    • Why CNAME/MX/NS targets require a "dot"
  • Provider
    • Supported providers
    • Akamai Edge DNS
    • Amazon Route 53
    • AutoDNS
    • AXFR+DDNS
    • Azure DNS
    • Azure Private DNS
    • BIND
    • Bunny DNS
    • CentralNic Reseller (CNR) - formerly RRPProxy
    • Cloudflare
    • ClouDNS
    • CSC Global
    • deSEC
    • DigitalOcean
    • DNS Made Easy
    • DNSimple
    • DNS-over-HTTPS
    • DOMAINNAMESHOP
    • Dynadot
    • easyname
    • Exoscale
    • Gandi_v5
    • Gcore
    • Google Cloud DNS
    • Hetzner DNS Console
    • HEXONET
    • hosting.de
    • Huawei Cloud DNS
    • Hurricane Electric DNS
    • Internet.bs
    • INWX
    • Linode
    • Loopia
    • LuaDNS
    • Microsoft DNS Server on Microsoft Windows Server
    • Mythic Beasts
    • Namecheap
    • Name.com
    • Netcup
    • Netlify
    • NS1
    • OpenSRS
    • Oracle Cloud
    • OVH
    • Packetframe
    • Porkbun
    • PowerDNS
    • Realtime Register
    • RWTH DNS-Admin
    • Sakura Cloud
    • SoftLayer DNS
    • TransIP
    • Vultr
  • Commands
    • preview/push
    • check-creds
    • get-zones
    • get-certs
    • fmt
    • creds.json
    • Global Flag
    • Disabling Colors
  • Advanced features
    • CI/CD example for GitLab
    • CLI variables
    • Nameservers and Delegations
    • Notifications
    • Useful code tricks
    • JSON Reports
  • Developer info
    • Code Style Guide
    • Documentation Style Guide
    • DNSControl is an opinionated system
    • Writing new DNS providers
    • Creating new DNS Resource Types (rtypes)
    • Integration Tests
    • Test a branch
    • Unit Testing DNS Data
    • Bug Triage Process
    • Bring-Your-Own-Secrets for automated testing
    • Debugging with dlv
    • ALIAS Records
    • TXT record testing
    • DNS records ordering
  • Release
    • How to build and ship a release
    • Changelog v3.16.0
    • GitHub releases
Powered by GitBook
On this page
  • Step 0. Update dependencies
  • Step 1. Rebuild generated files
  • Step 2. Tag the commit in main that you want to release
  • Step 3. Create the release notes
  • Step 4. Announce it via email
  • Step 5. Get credit
  • Tip: How to bump the major version
  • Tip: Configuring GHA integration tests
  • Overview
  • How do I add a single new integration test?
  • How do I add a "bring your own keys" integration test?
  • Tip: How to rebuild flattener
  • Tip: How to update modules
Edit on GitHub
  1. Release

How to build and ship a release

These are the instructions for producing a release.

GitHub Actions (GHA) will do most of the work for you. You will need to edit the draft release notes and click a button to make the release public.

Please change the version number as appropriate. Substitute (for example)v4.2.0 any place you see $VERSION in this doc.

Step 0. Update dependencies

git checkout main
git checkout -b update_deps
go install github.com/oligot/go-mod-upgrade@latest
go-mod-upgrade
go mod tidy
git commit -m "CHORE: Update dependencies" go.sum go.mod

Step 1. Rebuild generated files

git fetch origin main
git reset --hard origin/main
git checkout -b generate
bin/generate-all.sh
git status
git commit -am "CHORE: generate-all.sh"

Step 2. Tag the commit in main that you want to release

export VERSION=v4.x.0
git checkout main
git tag -m "Release $VERSION" -a $VERSION
git push origin HEAD --tags

Step 3. Create the release notes

The draft release notes are created for you. In this step you'll edit them.

Release notes style guide:

  • Entries in the bullet list should be phrased in the positive: "Feature FOO now does BAR". This is often the opposite of the related issue, which was probably phrased, "Feature FOO is broken because of BAR".

  • Every item should include the ID of the issue related to the change. If there was no issue, create one and close it.

  • Sort the list most important/exciting changes earlier in the list.

  • Items related to a specific provider should begin with the all-caps name of the provider, such as "ROUTE53: Added support for sandwiches (#100)"

  • The Deprecation warnings section should just copy from README.md. If you change one, change it in the README too (you can make that change in this PR).

Step 4. Announce it via email

Email the release notes to the mailing list: (note the format of the Subject line and that the first line of the email is the URL of the release)

To: dnscontrol-discuss@googlegroups.com
Subject: New release: dnscontrol v$VERSION

https://github.com/StackExchange/dnscontrol/releases/tag/v$VERSION

[insert the release notes here]

Step 5. Get credit

Mention the fact that you did this release in your weekly accomplishments.

If you are at Stack Overflow:

  • Add the release to your weekly snippets

Tip: How to bump the major version

If you bump the major version, you need to change all the source files. The last time this was done (v3 -> v4) these two commands were used. They're included her for reference.

#  Make all the changes:
sed -i.bak -e 's@github.com.StackExchange.dnscontrol.v3@github.com/StackExchange/dnscontrol/v4@g' go.* $(fgrep -lri --include '*.go' github.com/StackExchange/dnscontrol/v3 *)
# Delete the backup files:
find * -name \*.bak -delete

Tip: Configuring GHA integration tests

Overview

GHA is configured to run an integration test for any provider listed in the "provider" list. However the test is skipped if the *_DOMAIN variable is not set. For example, the Google Cloud provider integration test is only run if GCLOUD_DOMAIN is set.

  • Q: Where is the list of providers to run integration tests on?

  • A: In .github/workflows/pr_test.yml: (1) the "PROVIDERS" list, (2) the integrtests-diff2 section.

  • Q: Where are non-secret environment variables stored?

  • A: GHA calls them "Variables". Update them here: https://github.com/StackExchange/dnscontrol/settings/variables/actions

  • Q: Where are SECRET environment variables stored?

  • A: GHA calls them "Secrets". Update them here: https://github.com/StackExchange/dnscontrol/settings/secrets/actions

How do I add a single new integration test?

  1. Edit .github/workflows/pr_test.yml

  2. Add the FOO_DOMAIN variable name of the provider to the "PROVIDERS" list.

  3. Set the FOO_DOMAIN variables in GHA via https://github.com/StackExchange/dnscontrol/settings/variables/actions

  4. All other variables should be stored as secrets (for consistency). Add them to the integration-tests section. Set them in GHA via https://github.com/StackExchange/dnscontrol/settings/secrets/actions

How do I add a "bring your own keys" integration test?

Overview: You will fork the repo and add any secrets to your fork. For security reasons you won't have access to the secrets from the main repository.

  1. If you already have a fork, be sure to use the "sync fork" button on the main page to sync with the upstream.

  2. In your fork, set the ${DOMAIN}_DOMAIN variable in GHA via Settings :: Secrets and variables :: Actions :: Variables.

  3. In your fork, set any secrets in GHA via Settings :: Secrets and variables :: Actions :: Secrets.

  4. Start a build

Tip: How to rebuild flattener

Rebuilding flatter requires go1.17.1 and the gopherjs compiler.

Install go1.17.1:

go install golang.org/dl/go1.17.1@latest
go1.17.1 download
go install github.com/gopherjs/gopherjs@latest

Build the software:

NOTE: GOOS can't be Darwin because GOPHERJS doesn't support it.

cd docs/flattener/
export GOPHERJS_GOROOT="$(go1.17.1 env GOROOT)"
export GOOS=linux
gopherjs build

Tip: How to update modules

List out-of-date modules and update any that seem worth updating:

go install github.com/oligot/go-mod-upgrade@latest
go-mod-upgrade
go mod tidy

OLD WAY:

go install github.com/psampaz/go-mod-outdated@latest
go list -mod=mod -u -m -json all | go-mod-outdated -update -direct

# If any are out of date, update via:

go get module/path

# Once the updates are complete, tidy up:

go mod tidy
PreviousDNS records orderingNextChangelog v3.16.0

Last updated 2 months ago

Soon after GitHub will start an Workflow called "draft release" which will build all release binaries and write the draft release notes.

The GHA workflow uses which produces the with Release Notes derived from the commit history between now and the last tag. These notes are just a draft and needs considerable editing. These release notes are used elsewhere, in particular the email step.

See for examples for recent release notes and copy that style.

NOTE: You won't be able to post to the mailing list unless you are on it. .

in GitHub.

Install :

Action
GoReleaser
GitHub Release
https://github.com/StackExchange/dnscontrol/releases
Click here to join
Fork StackExchange/dnscontrol
GopherJS