where to find httpd.conf file on shared hosting? - shared-hosting

I am using A2 hosting shared server and need httpd.conf file for wildcard subdomain but I am not able to find httpd.conf on a shared server. where I can find this?

Related

Creating VirtualHost in httpd.conf file aws

I have an PHP website up and running on AWS setup with elastic beanstalk. Its running httpd server and I am unable to figure out as how to create virtual host to run multiple sites. The httpd.conf file doesn't have VirtualHost tag and I am unable to figure out as how to create one. Please let me know as how to configure it.
I think the best solution is to create a elasticbeanstalk.conf file in the .ebextensions directory and you specify in it the changes you want to make in the apache config
Actually the best solution is to include virtual host tags within the file and then defining the directory path in those tags.

Where to put Apache vhost configuration (httpd-vhosts.conf or httpd.conf)?

I just to ask a simple question. I am studying the vhost configuration but I am confused where should I properly put my vhosts configuration?
I have a file that has a name httpd-vhosts.conf and httpd.conf
I try to put my configuration in these 2 files but different web projects. And after I restarted my Wampserver I can access them. Is it fine if I place all my vhost entries in the file httpd-vhosts.conf ? Or should I place it in httpd.conf
There is no right or wrong. Apache has one global config file, which typically is the default or specified in the startup script.
This file then uses one or more secondary config files and directories. Different Linux distributions use different default include directories.
On CentOS I think for example you would put a file (named like your domain but can be anything) in /etc/httpd/conf.d/example-com.conf: http://wiki.centos.org/TipsAndTricks/ApacheVhostDir

Apache Web Server - How do I make my index page point to one of the folders

I have establish a web server on ubuntu.I have created some web sites on apache, each site has different folder.
In order to browse to my site website1 for example I need to type mymachine/Website1.
I want to type mymachine and it will redirect to the folder website1 , i.e. to my website.
Any suggestion, tried several settings.
Thanks
You have to it with Virtual hosts option,
first: you need to make specific folder in /var/www/..
second: point your folders with ServerName in Virtualhost file

Disable directory browsing in httpd.conf versus .htaccess on apaches

What is the best practice to disable directory browsing on an apache2 webserver? I am thinking disabling this at the httpd.conf would restrict browsing even if somebody gained access to the .htaccess file on the webserver and enabled directory browsing? Thoughts?
It's simpler via the server config but htaccess is often the only way. Especially on shared hosting.
If someone manipulates the htaccess file you don't need to protect your files. In that case it is already too late.

Multiple DocumentRoot in XAMPP or Apache

What would be the best way to set up XAMPP so that when I go to
http://localhost1 it access the folder C:\localhost1
and when I type
http://localhost2 it access the folder C:\localhost2?
I've done a response yesterday that should fit your needs:
Modify htaccess file for two sites
Use Alias in apache conf
http://www.apachefriends.org/f/viewtopic.php?f=16&t=36801
Make XAMPP/Apache serve file outside of htdocs