我最近在我的apache2服务器上安装了乘客apache模块,以便能够在rails应用程序上提供我的ruby。
我安装了 - apache2服务器,rvm,gem rails,gem passenger,passenger-install-apache2-module
我已将多个域指向/ var / www /上服务器上的应用程序,包括eurohacktrip.org上的rails应用程序
我的问题是,所有其他域名也都提供相同的rails应用程序。
位于/etc/apache2/apache2.conf
的底部Include sites-enabled/
LoadModule passenger_module /usr/local/rvm/gems/ruby-2.1.1/gems/passenger-4.0.50/buildout/apache2/mod_passenger.so
<IfModule mod_passenger.c>
PassengerRoot /usr/local/rvm/gems/ruby-2.1.1/gems/passenger-4.0.50
PassengerDefaultRuby /usr/local/rvm/gems/ruby-2.1.1/wrappers/ruby
</IfModule>
ON - /etc/apache2/sites-enabled/eurohacktrip.org
<VirtualHost *:80>
ServerName eurohacktrip.org
ServerAlias www.eurohacktrip.org
ServerAdmin webmaster@eurohacktrip.org
RailsEnv production
PassengerEnabled on
PassengerAppRoot /var/www/eurohacktrip.org/
PassengerRuby /usr/local/rvm/gems/ruby-2.1.1/wrappers/ruby
DocumentRoot /var/www/eurohacktrip.org/public
<Directory /var/www/eurohacktrip.org/public>
Options -MultiViews
AllowOverride All
# Order allow,deny
</Directory>
</VirtualHost>
ON - /etc/apache2/sites-enabled/tradesoko.com(laravel,php)
<VirtualHost *:80>
ServerAdmin webmaster@tradesoko.com
ServerName tradesoko.com
ServerAlias www.tradesoko.com
DocumentRoot /var/www/tradesoko.com/public
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory /var/www/tradesoko.com/public>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
# Order allow,deny
# allow from all
</Directory>
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/access.log combined
Alias /doc/ "/usr/share/doc/"
<Directory "/usr/share/doc/">
Options Indexes MultiViews FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
Allow from 127.0.0.0/255.0.0.0 ::1/128
</Directory>
</VirtualHost>
如何启用tradesoko.com?