Setting up multiple websites on Apache Httpd renders one site only accessible

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
0
down vote

favorite












I am planning to setup bugzilla and Orangescrum on one server. I did the following configuration in httpd.conf



<VirtualHost *:80>
DocumentRoot /var/www/html/
<Directory /var/www/html/bugzilla>
AddHandler cgi-script .cgi
Options +Indexes +ExecCGI
DirectoryIndex index.cgi
# AllowOverride Limit FileInfo Indexes
AllowOverride All
</Directory>
<Directory /var/www/html/project>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
</VirtualHost>


With this configuration everything works fine. http://server-addres returns Apache's index, http://server-address/bugzilla opens bugzilla and http://server-address/project opens orangescrum.



Now I have searched over the Internet and I found that setting up multiple websites works differently than I did by setting up individual virtual hosts like here for example. I did as in the website and for some reason http://server-address returns bugzilla, http://server-address/project gives me not found. The sites-enabled/bugzilla.conf contents are



<VirtualHost *:80>
DocumentRoot /var/www/
ErrorLog /var/www/bugzilla/error.log
CustomLog /var/www/bugzilla/requests.log combined
<Directory /var/www/bugzilla>
AddHandler cgi-script .cgi
Options +Indexes +ExecCGI
DirectoryIndex index.cgi
# AllowOverride Limit FileInfo Indexes
AllowOverride All
</Directory>
</VirtualHost>


and sites-enabled/project.conf contents are:



<VirtualHost *:80>
DocumentRoot /var/www/
ErrorLog /var/www/project/error.log
CustomLog /var/www/project/requests.log combined
<Directory /var/www/project>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
</VirtualHost>


Am I setting up the two websites correctly? What went wrong with my configurations?



Another issue is setting up https for both websites. I followed the instructions here on the httpd.conf I provided here and https://server/bugzilla opens as FTP server while https://server/project is still not found. Any idea on setting up https for multiple websites? Thanks!



Update: Do I really need multiple virtual hosts? I went with the first configuration I provided and everything works with the addition of the following for SSL:



SSLEngine on
SSLCertificateFile /etc/pki/tls/certs/ca.crt
SSLCertificateKeyFile /etc/pki/tls/private/ca.key
ServerName https://ip-address


And all 3 adresses https://ip-address, https://ip-address/project and https://ip-address/bugzilla work fine as expected.







share|improve this question






















  • You are missing ServerName and/or ServerAlias directives.
    – ivanivan
    Feb 26 at 11:28










  • This is a local server. What should I set these to? hostname? IP?
    – 3bdalla
    Feb 26 at 11:29










  • And the same for each vhost?
    – 3bdalla
    Feb 26 at 11:30














up vote
0
down vote

favorite












I am planning to setup bugzilla and Orangescrum on one server. I did the following configuration in httpd.conf



<VirtualHost *:80>
DocumentRoot /var/www/html/
<Directory /var/www/html/bugzilla>
AddHandler cgi-script .cgi
Options +Indexes +ExecCGI
DirectoryIndex index.cgi
# AllowOverride Limit FileInfo Indexes
AllowOverride All
</Directory>
<Directory /var/www/html/project>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
</VirtualHost>


With this configuration everything works fine. http://server-addres returns Apache's index, http://server-address/bugzilla opens bugzilla and http://server-address/project opens orangescrum.



Now I have searched over the Internet and I found that setting up multiple websites works differently than I did by setting up individual virtual hosts like here for example. I did as in the website and for some reason http://server-address returns bugzilla, http://server-address/project gives me not found. The sites-enabled/bugzilla.conf contents are



<VirtualHost *:80>
DocumentRoot /var/www/
ErrorLog /var/www/bugzilla/error.log
CustomLog /var/www/bugzilla/requests.log combined
<Directory /var/www/bugzilla>
AddHandler cgi-script .cgi
Options +Indexes +ExecCGI
DirectoryIndex index.cgi
# AllowOverride Limit FileInfo Indexes
AllowOverride All
</Directory>
</VirtualHost>


and sites-enabled/project.conf contents are:



<VirtualHost *:80>
DocumentRoot /var/www/
ErrorLog /var/www/project/error.log
CustomLog /var/www/project/requests.log combined
<Directory /var/www/project>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
</VirtualHost>


Am I setting up the two websites correctly? What went wrong with my configurations?



Another issue is setting up https for both websites. I followed the instructions here on the httpd.conf I provided here and https://server/bugzilla opens as FTP server while https://server/project is still not found. Any idea on setting up https for multiple websites? Thanks!



Update: Do I really need multiple virtual hosts? I went with the first configuration I provided and everything works with the addition of the following for SSL:



SSLEngine on
SSLCertificateFile /etc/pki/tls/certs/ca.crt
SSLCertificateKeyFile /etc/pki/tls/private/ca.key
ServerName https://ip-address


And all 3 adresses https://ip-address, https://ip-address/project and https://ip-address/bugzilla work fine as expected.







share|improve this question






















  • You are missing ServerName and/or ServerAlias directives.
    – ivanivan
    Feb 26 at 11:28










  • This is a local server. What should I set these to? hostname? IP?
    – 3bdalla
    Feb 26 at 11:29










  • And the same for each vhost?
    – 3bdalla
    Feb 26 at 11:30












up vote
0
down vote

favorite









up vote
0
down vote

favorite











I am planning to setup bugzilla and Orangescrum on one server. I did the following configuration in httpd.conf



<VirtualHost *:80>
DocumentRoot /var/www/html/
<Directory /var/www/html/bugzilla>
AddHandler cgi-script .cgi
Options +Indexes +ExecCGI
DirectoryIndex index.cgi
# AllowOverride Limit FileInfo Indexes
AllowOverride All
</Directory>
<Directory /var/www/html/project>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
</VirtualHost>


With this configuration everything works fine. http://server-addres returns Apache's index, http://server-address/bugzilla opens bugzilla and http://server-address/project opens orangescrum.



Now I have searched over the Internet and I found that setting up multiple websites works differently than I did by setting up individual virtual hosts like here for example. I did as in the website and for some reason http://server-address returns bugzilla, http://server-address/project gives me not found. The sites-enabled/bugzilla.conf contents are



<VirtualHost *:80>
DocumentRoot /var/www/
ErrorLog /var/www/bugzilla/error.log
CustomLog /var/www/bugzilla/requests.log combined
<Directory /var/www/bugzilla>
AddHandler cgi-script .cgi
Options +Indexes +ExecCGI
DirectoryIndex index.cgi
# AllowOverride Limit FileInfo Indexes
AllowOverride All
</Directory>
</VirtualHost>


and sites-enabled/project.conf contents are:



<VirtualHost *:80>
DocumentRoot /var/www/
ErrorLog /var/www/project/error.log
CustomLog /var/www/project/requests.log combined
<Directory /var/www/project>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
</VirtualHost>


Am I setting up the two websites correctly? What went wrong with my configurations?



Another issue is setting up https for both websites. I followed the instructions here on the httpd.conf I provided here and https://server/bugzilla opens as FTP server while https://server/project is still not found. Any idea on setting up https for multiple websites? Thanks!



Update: Do I really need multiple virtual hosts? I went with the first configuration I provided and everything works with the addition of the following for SSL:



SSLEngine on
SSLCertificateFile /etc/pki/tls/certs/ca.crt
SSLCertificateKeyFile /etc/pki/tls/private/ca.key
ServerName https://ip-address


And all 3 adresses https://ip-address, https://ip-address/project and https://ip-address/bugzilla work fine as expected.







share|improve this question














I am planning to setup bugzilla and Orangescrum on one server. I did the following configuration in httpd.conf



<VirtualHost *:80>
DocumentRoot /var/www/html/
<Directory /var/www/html/bugzilla>
AddHandler cgi-script .cgi
Options +Indexes +ExecCGI
DirectoryIndex index.cgi
# AllowOverride Limit FileInfo Indexes
AllowOverride All
</Directory>
<Directory /var/www/html/project>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
</VirtualHost>


With this configuration everything works fine. http://server-addres returns Apache's index, http://server-address/bugzilla opens bugzilla and http://server-address/project opens orangescrum.



Now I have searched over the Internet and I found that setting up multiple websites works differently than I did by setting up individual virtual hosts like here for example. I did as in the website and for some reason http://server-address returns bugzilla, http://server-address/project gives me not found. The sites-enabled/bugzilla.conf contents are



<VirtualHost *:80>
DocumentRoot /var/www/
ErrorLog /var/www/bugzilla/error.log
CustomLog /var/www/bugzilla/requests.log combined
<Directory /var/www/bugzilla>
AddHandler cgi-script .cgi
Options +Indexes +ExecCGI
DirectoryIndex index.cgi
# AllowOverride Limit FileInfo Indexes
AllowOverride All
</Directory>
</VirtualHost>


and sites-enabled/project.conf contents are:



<VirtualHost *:80>
DocumentRoot /var/www/
ErrorLog /var/www/project/error.log
CustomLog /var/www/project/requests.log combined
<Directory /var/www/project>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
</VirtualHost>


Am I setting up the two websites correctly? What went wrong with my configurations?



Another issue is setting up https for both websites. I followed the instructions here on the httpd.conf I provided here and https://server/bugzilla opens as FTP server while https://server/project is still not found. Any idea on setting up https for multiple websites? Thanks!



Update: Do I really need multiple virtual hosts? I went with the first configuration I provided and everything works with the addition of the following for SSL:



SSLEngine on
SSLCertificateFile /etc/pki/tls/certs/ca.crt
SSLCertificateKeyFile /etc/pki/tls/private/ca.key
ServerName https://ip-address


And all 3 adresses https://ip-address, https://ip-address/project and https://ip-address/bugzilla work fine as expected.









share|improve this question













share|improve this question




share|improve this question








edited Feb 26 at 12:12

























asked Feb 26 at 11:02









3bdalla

142820




142820











  • You are missing ServerName and/or ServerAlias directives.
    – ivanivan
    Feb 26 at 11:28










  • This is a local server. What should I set these to? hostname? IP?
    – 3bdalla
    Feb 26 at 11:29










  • And the same for each vhost?
    – 3bdalla
    Feb 26 at 11:30
















  • You are missing ServerName and/or ServerAlias directives.
    – ivanivan
    Feb 26 at 11:28










  • This is a local server. What should I set these to? hostname? IP?
    – 3bdalla
    Feb 26 at 11:29










  • And the same for each vhost?
    – 3bdalla
    Feb 26 at 11:30















You are missing ServerName and/or ServerAlias directives.
– ivanivan
Feb 26 at 11:28




You are missing ServerName and/or ServerAlias directives.
– ivanivan
Feb 26 at 11:28












This is a local server. What should I set these to? hostname? IP?
– 3bdalla
Feb 26 at 11:29




This is a local server. What should I set these to? hostname? IP?
– 3bdalla
Feb 26 at 11:29












And the same for each vhost?
– 3bdalla
Feb 26 at 11:30




And the same for each vhost?
– 3bdalla
Feb 26 at 11:30















active

oldest

votes











Your Answer







StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
convertImagesToLinks: false,
noModals: false,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);








 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f426651%2fsetting-up-multiple-websites-on-apache-httpd-renders-one-site-only-accessible%23new-answer', 'question_page');

);

Post as a guest



































active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes










 

draft saved


draft discarded


























 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f426651%2fsetting-up-multiple-websites-on-apache-httpd-renders-one-site-only-accessible%23new-answer', 'question_page');

);

Post as a guest













































































Popular posts from this blog

How to check contact read email or not when send email to Individual?

Bahrain

Postfix configuration issue with fips on centos 7; mailgun relay