wstar

Member
Oct 7, 2014
6
0
1
cPanel Access Level
Reseller Owner
I see a few different posts, but I don't see this same question on here.
I have a site home directory as home/USERNAME. We also have a development site for testing. When I make a subdomain, it puts it in home/USERNAME/development folder. We would like to separate these like so

Main Site: home/USERNAME/site
Development Site: home/USERNAME/dev

I have full access to the server, even through WHM. I'm guessing I would have to change the httpd.conf file? And would there be one httpd.conf for both?

Thanks for any help in this issue.
 

wstar

Member
Oct 7, 2014
6
0
1
cPanel Access Level
Reseller Owner
When creating the subdomain, the directory is set to the home directory then a subfolder.
Ex. home/USERNAME/subdomain
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,910
2,216
363
Hello :)

You can choose the document root of your preference when creating the subdomain. For instance, it can be in the account's home directory or within the public_html directory. Is it not working as intended when you do this?

Thank you.
 

wstar

Member
Oct 7, 2014
6
0
1
cPanel Access Level
Reseller Owner
Thanks for the quick replies.
When I create a subdomain I can attach and folder(s) to the end of the home directly. But I wanted to see if there was a way to make it different than the home directory.

My end goal is to have this
Main Site: home/USERNAME/site
Development Site: home/USERNAME/dev

I just don't want the development site to be home/USERNAME/site/dev
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,910
2,216
363
Could you attach a screenshot of what you see when attempting to modify the directory during the subdomain creation?

Thank you.
 

wstar

Member
Oct 7, 2014
6
0
1
cPanel Access Level
Reseller Owner
Yeah I can when I get home. I think my first step is to change the home directory for the site?
To home/USERNAME/site instead of the default home/USERNAME/ ?
 

Infopro

Well-Known Member
May 20, 2003
17,112
513
613
Pennsylvania
cPanel Access Level
Root Administrator
Twitter
We would like to separate these like so

Main Site: home/USERNAME/site
Development Site: home/USERNAME/dev
So, on the Create a Subdomain page, you'd do this:

Subdomain: dev
Domain: domain.com
Document root: /dev
You'll need to edit the auto filled details here.

The docs should be of some use:

Subdomains - cPanel Documentation