keep "stats" and other icon folders outside of the public_html

4 posts / 0 new
Last post
#1 Tue, 01/20/2015 - 07:20
mehargags

keep "stats" and other icon folders outside of the public_html

Pardon if this was asked before, I wanted to know how I can keep my public_html folder absolutely clean and lean comprising my site files only. Virtualmin creates these default folders: awstats-icon  awstatsicons  icon  stats

I'd prefer to keep stats and other icon folders outside of the public_html folder.

thanks alot!

Thu, 01/22/2015 - 09:59
tpnsolutions
tpnsolutions's picture

Hi,

These files and symbolic links are used by "AWStats" so if you don't need this feature you simply can remove the feature from the domain and safely remove folders/symbolic links.

Best Regards,
Peter Knowles
TPN Solutions

Email: pknowles@tpnsolutions.com
Phone: 604-782-9342
Skype: tpnsupport
Website: http://www.tpnsolutions.com

Ask me about my new support plans which include a FREE copy of Virtualmin Pro!!!

Best Regards,
Peter Knowles | TPN Solutions
Email: pknowles@tpnsolutions.com | Skype: tpnassist
Fri, 01/23/2015 - 02:13
mehargags

Thanks... But I DO WANT to USE AWStats, Can I not have these folders outside of my Public_html folder? There must be some AWStats config file where we can change the default path behavior for this ?

Fri, 01/23/2015 - 17:48 (Reply to #3)
Joe
Joe's picture

That'd be somewhat tricky. You'd need an additional Directory section added to each VirtualHost in the Apache configuration. You could do that in Server Templates (you can add arbitrary Apache configuration for each new VirtualHost with Server Templates in the Apache section)...but, you'd also need the Virtualmin AWStats module to know about that, which it doesn't look like it is configurable in that way. So, some code would need to be written in virtualmin-awstats.

That happens in this function:

sub get_htmldir
{
return &virtual_server::public_html_dir($_[0]);
}

Not sure if it'd be as simple as making a new config option for where you want it to go, and returning that if it's set...but, might be. That would only be 2 additional lines of code and one config file directive, I think, if it would work that way. But, would probably also require some additional stuff in the module to setup that Directory section.

--

Check out the forum guidelines!

Topic locked