Mass Update SPF Records

I am trying to mass update all the SPF records for all domains on my server. I have used the following command to add the 4 IP4 addresses fine.

virtualmin modify-dns

The issue I now have is I also need to add a “includes” hostname. For example I can do this by going to DNS Options and I can see the setting called “Included domains to allow”. However I cannot see away to do this via cli using the “modify-dns” tool.

Am I going to have to manually do this for every domain?

Shane

Hey shanerutter, not sure if you’ve already found a solution but I just ran accross this post which might help you.

https://www.virtualmin.com/node/4889

Howdy,

Hmm, I’m not positive, but I think this option might do what you’re after:

–spf-add-a HOSTNAME

If you run that for one of your domains, and then look at the results in the DNS Options screen, does it update the field you’re after?

-Eric