|
#1
|
|||
|
|||
|
Anyone know how to create subdomains from the command line? I know how to do it from cpanel, but I'm trying to script out my setup process.
I've updated the following files and the sub-domain does not come up on the browser.... /etc/httpd/conf/httpd.conf /var/named/mydomain.com.db /etc/localdomains /etc/userdomains Am I missing any other files? Thanks, Neil |
|
#2
|
||||
|
||||
|
There are also the cPanel user file and the cPanel user meta file
/var/cpanel/users/USERNAME /var/cpanel/userdata/USERNAME/subdomain.file There are a number of advantages to not editing the apache configuration file as your changes will probably get overwritten during an update. cPanel/WHM builds that configuration file from various metadata files that should be edited instead. If you are looking to script the creation of subdomains, I suggest using the cPanel API. More information on the addsubdomain function can be found here: http://docs.cpanel.net/twiki/bin/vie...n_addsubdomain There are also a few php scripts set up to perform this same thing that have been passed around on the cPanel forums. |
|
#3
|
|||
|
|||
|
Thanks GatorBClemmer!
If anyone has already written a script to create a sub-domains, could you please email it to me? I would really appreciate it! Thanks |
|
#4
|
||||
|
||||
|
Searched in the cPanel forums and found this:
http://www.zubrag.com/scripts/cpanel...ns-creator.php
__________________
quietFinn - netFinn Finland "Be who you are and say what you feel because those who mind don't matter and those who matter don't mind." - Dr. Seuss |
|
#5
|
|||
|
|||
|
Perfect Thanks!
I'll modify the script as needed... |
![]() |
| Bookmarks |
«
Previous Thread
|
Next Thread
»
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Cron and command line help!! Please!! | duetime | Shared Hosting Support | 3 | 06-17-2009 01:08 PM |
| Java command line | gemal | Shared Hosting Support | 0 | 06-26-2008 09:46 AM |
| Can I use cpan from the command line? | gaarai | Shared Hosting Support | 2 | 07-07-2007 05:27 PM |
| Creating MySQL Databases from the command line - permission denied | patwa | Shared Hosting Support | 5 | 06-29-2007 05:20 PM |
All times are GMT -5. The time now is 01:05 PM.









