Automatic index page when account is created?

Vger

Registered
Nov 2, 2009
1
0
51
I apologise if this has been asked before. I have searched but didn't find anything.

We have our first WHM/cPanel server online. All others are Ensim Pro and I am used to a default homepage being created whenever a new site is added, but this does not appear to happen with WHM/cPanel.

Presumably such a facility exists, but I need assistance on how to set things up so that any new account gets a default homepage.

Many Thanks - Vger
 

cpanelinfoseeker

Well-Known Member
Oct 25, 2002
323
3
168
NE Illinois
cPanel Access Level
Root Administrator
In WHM, look for "Account Functions" and choose "Skeleton Directory". This will show you where your directory is. Anything you add to your skel directory will automatically be added to the users directory when you create a new account.

Ron
 

cPanelDon

cPanel Quality Assurance Analyst
Staff member
Nov 5, 2008
2,545
12
268
Houston, Texas, U.S.A.
cPanel Access Level
DataCenter Provider
Twitter
That is correct; for example, if you place a default HTML page within the "public_html" sub-directory then it will be included within the public_html directory of the user's new account upon creation.

Example paths:
Code:
/root/cpanel3-skel
/root/cpanel3-skel/public_html
/root/cpanel3-skel/public_html/index.html
 

maderite

Registered
Nov 4, 2009
4
0
51
is there a way to do this depending on the package assigned when creating an account.

Lets say i host alot of istes on a certain php script and want the files added in when i assign a certain package for creation
but if its just a standard hosting account i dont want it included.
 

cPanelDon

cPanel Quality Assurance Analyst
Staff member
Nov 5, 2008
2,545
12
268
Houston, Texas, U.S.A.
cPanel Access Level
DataCenter Provider
Twitter
is there a way to do this depending on the package assigned when creating an account.

Lets say i host alot of istes on a certain php script and want the files added in when i assign a certain package for creation
but if its just a standard hosting account i dont want it included.
This should be possible by using a "hook" (i.e., "postwwwacct"); this could be a custom script that runs after a new account is created, and the custom script could perform specific actions based upon the package.

Here is our related documentation that will help while getting started and while researching how to accomplish the automated provisioning based on the package:
WebHome < AllDocumentation/AutomationIntegration < TWiki

The following is a section within the above documentation, more specific to the request:
Hooking into cPanel Functionality
ScriptHooks < DevHooks < TWiki

On the "ScriptHooks" page, I recommend reading about "postwwwacct" as detailed in the documentation.

Moderator Note: So that your question can receive more relevant feedback and discussion I recommend posting in the Developer area of the forums: Developer Discussions - cPanel Forums