<div dir="ltr">Thank you Anand,<div><br></div><div>Would it be possible to look at your script and gitlab-ci yaml?  This is incredibly helpful.  Thank you so much.<br clear="all"><div><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><font face="monospace">Cameron Banowsky</font><div><font face="monospace">SHE BASH </font></div><div><font face="monospace">323-217-8592</font></div><div><a href="https://shebash.io" target="_blank"><font face="monospace">https://shebash.io</font></a></div><div><br></div><div><font face="monospace">The content of this email is confidential and intended for the recipient specified in message only. It is strictly forbidden to share any part of this message with any third party, without a written consent of the sender. If you received this message by mistake, please reply to this message and follow with its deletion, so that we can ensure such a mistake does not occur in the future.</font><br></div></div></div></div></div></div></div></div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Dec 8, 2020 at 1:54 PM Anand Buddhdev <<a href="mailto:anandb@ripe.net">anandb@ripe.net</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi Cameron,<br>
<br>
We do something like this for our zones. In our zone repository, I have<br>
a script called "checkzones". I can run it any time in my checkout of<br>
the repository, and it checks all the zones for various things. For<br>
example, it checks for implicit owner names, missing TTL, etc. It also<br>
runs "named-checkzone" for every zone. You can make the script as<br>
extensive as you like.<br>
<br>
Next, we have a GitLab CI/CD config file in the repo, that tells GitLab<br>
to spawn a docker image, check out the repository in there, and run the<br>
"checkzones" script. If it fails for any reason, the pipeline fails.<br>
<br>
Our GitLab repository is configured to prevent direct commits to the<br>
"master" branch. Instead, all users must create a separate branch, and<br>
push their commits to it. If the pipeline succeeds, GitLab merges the<br>
commit to master. If the pipeline fails, the user gets email, and they<br>
need to go and fix their mistakes with additional commits, until the<br>
pipeline succeeds.<br>
<br>
Regards,<br>
Anand<br>
<br>
On 08/12/2020 21:54, Cameron Banowsky wrote:<br>
<br>
> Seasons Greetings,<br>
> <br>
> We are managing our zone files in git and are looking for tools to<br>
> accomplish validation checks within our CI/CD pipeline. Does anyone have<br>
> any pro tips or code references for how we can optimize our user and admin<br>
> experience?  We are using Gitlab CI.<br>
> <br>
> For example, we would like to achieve input validation for zone entries,<br>
> check for syntax errors, automated zone file serial number incrementing,<br>
> and resolve new DNS entries in a staging server.<br>
> <br>
> Any and all help would be greatly appreciated.<br>
</blockquote></div>