netbox-powerdns-integration

Synchronize NetBox IPAM data with PowerDNS to create DNS records.

22|1|Updated Oct 24, 2025
One-click install
npx skills add https://github.com/basher83/lunar-claude --skill netbox-powerdns-integration
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: netbox-powerdns-integration
Source: https://github.com/basher83/lunar-claude/tree/main/plugins/homelab/netbox-powerdns-integration/skills/netbox-powerdns-integration
Command: npx skills add https://github.com/basher83/lunar-claude --skill netbox-powerdns-integration

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires pynetbox, infisicalsdk, rich, typer, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill eliminates manual DNS record management and inconsistent infrastructure documentation by integrating NetBox as the single source of truth with PowerDNS. It automates IP address management, DNS record creation, and dynamic inventory for configuration management, drastically reducing human error and saving time.

Core Features & Use Cases

  • Automated DNS Record Management: Automatically create A/AAAA and PTR records in PowerDNS when IPs are assigned in NetBox, using tags like production-dns.
  • Infrastructure as Code (IaC): Manage NetBox resources (IPs, devices, VMs) via Terraform, ensuring your infrastructure documentation is always in sync with reality.
  • Ansible Dynamic Inventory: Use NetBox as the real-time source for Ansible inventory, enabling tag-based host selection and automated configuration.
  • Use Case: Provision a new VM using Terraform. This Skill ensures its IP is registered in NetBox, and automatically creates the corresponding DNS records in PowerDNS, making the VM immediately discoverable and ready for Ansible configuration.

Quick Start

Create VM in NetBox with auto-assigned IP

./tools/netbox_vm_create.py --name docker-02 --cluster matrix --vcpus 4 --memory 8192

Query NetBox API for devices

./tools/netbox_api_client.py devices get --name foxtrot

Validate DNS Naming Convention

./tools/validate_dns_naming.py --name "docker-01-nexus.spaceships.work"

Frequently Asked Questions about netbox-powerdns-integration

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate DNS record creation when provisioning infrastructure with NetBox and PowerDNS?

Automate DNS record creation by synchronizing NetBox IPAM data with PowerDNS. When you assign IPs in NetBox, the Skill automatically generates A/AAAA and PTR records in PowerDNS using tag-based zone matching, eliminating manual DNS management and keeping infrastructure documentation consistent.

Can I use NetBox as a single source of truth for both infrastructure and DNS management?

Yes. NetBox serves as the single source of truth for IP address management and DNS records. The Skill integrates NetBox with PowerDNS to automatically synchronize device IPs, VMs, and DNS naming conventions across your infrastructure, reducing human error and ensuring real-time consistency.

How do I provision VMs with automatic DNS records using Terraform and Ansible?

Provision VMs via Terraform, which creates the IP in NetBox. The Skill automatically registers the IP and creates corresponding DNS records in PowerDNS. Use NetBox as dynamic inventory for Ansible to configure the VM immediately with the auto-generated DNS name.

Does this integration work with multi-zone PowerDNS setups and tag-based DNS naming conventions?

Yes. The Skill applies tag-based zone matching to route DNS records to the correct PowerDNS zones and implements zone-based DNS name generation. It handles multi-zone PowerDNS deployments while enforcing consistent DNS naming conventions across your infrastructure.

What dependencies do I need to integrate NetBox with PowerDNS for DNS automation?

The Skill requires pynetbox for NetBox API access, infisicalsdk for secure token retrieval, rich for CLI formatting, and typer for command-line tools. These enable secure API communication, credential management, and scriptable automation of DNS provisioning workflows.

Can I validate DNS naming conventions before records are created in PowerDNS?

Yes. The Skill includes validation tools to check DNS naming conventions before provisioning. Use the validate_dns_naming script to ensure names comply with your standards, preventing misaligned records from being created in PowerDNS.