2016-06-20 9 views
0

私はApacheのすべての不明なサブドメインをリダイレクトしたいと思いますか?例: "aaa.mydomain.com/bbb.mydomain.com/ccc.mydomain.com"は "all.domain.com"にリダイレクトされます。すべての未知のドメインをリダイレクト

私の現在のホスト:

>

ServerAdmin [email protected] 
    ServerName domain.dev 
    ServerAlias administration.domain.dev 
    ServerAlias agence.domain.dev 
    ServerAlias css.domain.dev 
    ServerAlias dev.domain.dev 
    ServerAlias dome.domain.dev 
    DocumentRoot /var/www/symfony/domain/web 
    <Directory /var/www/symfony/domain/web> 
      Options Indexes FollowSymLinks MultiViews 
      AllowOverride all 
      Order allow,deny 
      Allow from all 
      <IfModule mod_rewrite.c> 
        RewriteEngine On 
        RewriteCond %{REQUEST_FILENAME} !-f 
        RewriteRule ^(.*)$ /app.php [QSA,L] 
      </IfModule> 
    </Directory> 
    ErrorLog ${APACHE_LOG_DIR}/error_dev.domain.dev.log 
    LogLevel warn 
    CustomLog ${APACHE_LOG_DIR}/access_dev.domain.dev.log combined 

答えて

0

あなたがapacheのproxypass

を見て、リバースプロキシでこれを行うことができます
関連する問題