What would be the best way (in bash) to fetch the reseller based on domain?

tlweb

Verified User
Joined
Feb 23, 2015
Messages
39
Location
Netherlands
Hi,

I'm writing a bash script that is triggered on dnssec_sign_post to sync the dnssec info to my registrar.

But i'm facing the challenge or having other resellers on the server who also use the same registrar so for my script to know what domain to use i was thinking how i could go from domain.com to -> reseller where this domain belongs to. So it would be the reseller -> user -> domain.com.

it seems the API is not the way to go here. i'm probably better of parsing some files or something. Anyone know of the best place to get this information? It must be stored somewhere i guess.

Kind regards,

Tom
 
You can see domainowners like this:

Code:
cat /etc/virtual/domainowners

And you can see per reseller what users the reseller has in;
Where $RESELLER is the real reseller account offcourse.
Code:
/usr/local/directadmin/data/users/$RESELLER/users.list

This would be enough for you to combine it I think.

But the API has:

So you could also use the API as a reseller and get all the reseller users domains
 
Back
Top