Vigyata.AI
Is this your channel?

I Automated My DNS with GitLab and BIND (Here’s How)

846 views· 61 likes· 12:34· Jan 8, 2026

🛍️ Products Mentioned (1)

In this video I’ll walk through the setup and show how I automate updating my DNS using Gitlab CICD pipelines! Github Repo: https://github.com/sassdrew/homelab/tree/main/43-Automate-DNS-Updates-with-Gitlab Interested in other Homelab videos? Check out this playlist: https://www.youtube.com/playlist?list=PLhkW8M2MBf-H33LeTrVMc0LwN3EuOqGQV Wanting to automate your builds with Gitlab and Ansible? Check out this playlist: https://www.youtube.com/playlist?list=PLhkW8M2MBf-Gjb5qI-f1vPbXN530Hd1-3 For Business Inquiries you can email me at: sassdrew501@gmail.com

About This Video

In this homelab remake, I walk through how I automated my DNS updates so GitLab becomes the source of truth for my BIND zone files. The whole goal is simple: I don’t want to SSH into my DNS server every time I add a record. Instead, I use a GitLab project with CI/CD that validates my zone file, copies it to the DNS server, and then reloads BIND—all automatically. I start by generating an SSH keypair (non-interactive on purpose), adding the public key to the DNS server’s authorized_keys, and making sure permissions are correct (600) so SSH doesn’t freak out. On the GitLab side, I store the private key as a CI/CD variable (as a file) and call it by name in my pipeline. My .gitlab-ci.yml has two stages: validate (using bind-utils and named-checkzone) and deploy (write the SSH key to ~/.ssh/id_rsa, SCP the zone file over, then SSH in and reload the zones). I also show a quick test change—bump the serial, add a record—and you can see the pipeline push it through cleanly. It’s less manual work, more repeatable automation, and it scales way better than “log in and edit stuff.”

Frequently Asked Questions

🎬 More from sass drew