Automation, Dreamhost Control Panel

software development



Didnt know if I should post this in troubleshooting or programming so posting here :slight_smile:

Is there some other way of automating creation of subdomains and/or conditional skeleton setups than using wget or other simulated user agents? Using for example XMLRPC?


This has actually come up a few times before in the past few months. All such things (Domains, sub-domains, databases, E-mail, etc.) must be passed through the panel. You can set up a script to take the info submitted on your website, authenticate it self with the panel, and submit the information.

Keep in mind that you are responsible for all content store on your account, so if a user comes and puts up illegal sutff, or starts spamming, you’ll take all the heat and might well loose your account.

–Matttail - personal website


Alright, so have to simulate user agents some way then… been fiddling with a script to create a subdomain and this is what I’ve got thusfar:



Shouldn’t have to edit anything beyond this point

LOADSAVECOOKIES=”–save-cookies $COOKIEFILE --load-cookies $COOKIEFILE"

wget $PARMS --save-cookies $COOKIEFILE $DELA ""
wget $PARMS $LOADSAVECOOKIES $DELA --post-data=“Nscmd=Nlogin&username=$USER&password=$PASS&”
wget $PARMS $LOADSAVECOOKIES -O $OUTFILE --post-data=“current_step=ShowAddhttp&next_step=AddHttp&tree=domain.manage&domain_type=cgi&domain=&php_version=5&mod_security_on=1&usid=&relpath=&www_redir=notwww”
[/code]Took some (most) from Rodrigo Damazios Dynamic DNS script

This, for some reason unknown to me, doesnt work. Resulting page is some sort of advanced DNS setup for my domain. Anyone able to spot obvious errors? Is the referer header checked perhaps?


Not at this time, though it would be nice.

:cool: Perl / MySQL / HTML+CSS


Okay, I’ve resolved this issue with the help of an Perl script. Havent got it readily available now but if anyone is interested send me an PM and I’ll work something out.