Skip to content

Add acme-dns provider support#1033

Open
rbicker wants to merge 1 commit into
polymind-inc:masterfrom
arcadech:feat/acme-dns-provider
Open

Add acme-dns provider support#1033
rbicker wants to merge 1 commit into
polymind-inc:masterfrom
arcadech:feat/acme-dns-provider

Conversation

@rbicker

@rbicker rbicker commented May 8, 2026

Copy link
Copy Markdown

Summary

Add built-in support for the acme-dns (https://github.com/acme-dns/acme-dns) DNS provider.

This implementation uses configured synthetic zones so the existing suffix-based DNS provider matching logic can be reused. It is intended for the standard acme-dns workflow where the user:

  1. Pre-registers with acme-dns
  2. Creates the _acme-challenge CNAME in the primary DNS zone
  3. Configures the delegated domain mapping and credentials in Acmebot

Configuration

Example app settings:

  • Acmebot__AcmeDns__Endpoint
  • Acmebot__AcmeDns__PropagationSeconds
  • Acmebot__AcmeDns__Zones__0__Name
  • Acmebot__AcmeDns__Zones__0__Subdomain
  • Acmebot__AcmeDns__Zones__0__Username
  • Acmebot__AcmeDns__Zones__0__Password

Notes

  • acme-dns cleanup is intentionally a no-op because the upstream API supports record updates but not record deletion.
  • This change does not automate acme-dns registration or primary DNS CNAME creation.

Validation

  • dotnet restore ./Acmebot.slnx
  • dotnet build -c Release ./Acmebot.slnx
  • dotnet format --verify-no-changes --verbosity detailed --no-restore ./Acmebot.slnx
  • bicep build ./deploy/azuredeploy.bicep

Copilot AI review requested due to automatic review settings May 8, 2026 10:22

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new built-in DNS provider implementation for acme-dns so Acmebot can perform delegated DNS-01 challenges via configured “synthetic zones”, reusing the existing suffix-based zone matching logic.

Changes:

  • Introduces AcmeDnsProvider with configurable endpoint, propagation delay, and per-zone delegated subdomain + credentials.
  • Wires the new provider into DNS provider registration and top-level options (AcmebotOptions).
  • Updates documentation site provider list/count and refreshes the generated ARM template output.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/Acmebot.App/Providers/AcmeDnsProvider.cs New DNS provider implementation that calls the acme-dns update API to set TXT challenge values.
src/Acmebot.App/Program.cs Registers AcmeDnsProvider when Acmebot:AcmeDns configuration is present.
src/Acmebot.App/Options/AcmeDnsOptions.cs Adds options model for acme-dns endpoint, propagation delay, and zone mappings/credentials.
src/Acmebot.App/Options/AcmebotOptions.cs Exposes AcmeDns as a configurable DNS provider option.
docs/index.html Updates DNS provider count/list and adjusts the “providers note” copy to mention acme-dns.
deploy/azuredeploy.json Updates generated ARM template metadata and role assignment scope expression output.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +18 to +22
var duplicateZoneNames = options.Zones.GroupBy(x => x.Name, StringComparer.OrdinalIgnoreCase)
.Where(x => x.Count() > 1)
.Select(x => x.Key)
.ToArray();

Comment on lines +56 to +59
foreach (var value in values.Distinct(StringComparer.Ordinal))
{
await _acmeDnsClient.UpdateTxtRecordAsync(zoneOption, value, cancellationToken);
}
message.Headers.TryAddWithoutValidation("X-Api-User", zone.Username);
message.Headers.TryAddWithoutValidation("X-Api-Key", zone.Password);

var response = await _httpClient.SendAsync(message, cancellationToken);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants