I need to add a lot of domains to Mail Proxy -> Relay Domains (about 600). It would be not good job to do this one by one in the web interface. Is there any option to do this on the command line having all domains in a text file?
Thank you. I am not used to the API - seems that I should change this ;-)
One question: if I understand the API call correct it only accepts one domain per call - or is it possible to send an array with many domains?
the API call only takes one domain - you need to loop over your list of domains to add them.
if you only want to add relay-domains - this (currently) can also be accomplished by editing '/etc/pmg/domains' and running `postmap /etc/pmg/domains` and reloading postfix afterwards .
@tom is correct - the API is usually preferable (it guarantees that everything is done in the right way and order)!
Thank you very much - I am already learning to use the api. Making my own scripts will help a lot, when there is the need for import or similar things. All typical tasks I do with your Webinterface, which is pretty good .
But your tip for editing the "domains" is really the fastest way now for this special task - this saves me time until I am fit in using the api!
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.