2013-07-24 3 views
1

나는 아파치의 가상 호스트 구성에 어려움을 겪고있다. 여기 아파치 가상 호스트 - cgit을위한 서브 도메인

<VirtualHost *> 
    ServerAdmin [email protected] 
    ServerName cgit.mydomain.org 
    ErrorLog "/var/log/httpd/cgit-error_log" 
    CustomLog "/var/log/httpd/cgit-access_log" common 
    DocumentRoot "/usr/share/webapps/cgit/" 

    <Directory "/usr/share/webapps/cgit/"> 
     AllowOverride None 
     Options ExecCGI FollowSymlinks 
     Order allow,deny 
     Allow from all 
    </Directory> 

    Alias /cgit.css "/usr/share/webapps/cgit/cgit.css" 
    Alias /cgit.png "/usr/share/webapps/cgit/cgit.png" 
    Alias /favicon.ico "/usr/share/webapps/cgit/favicon.ico" 
    ScriptAlias/"/usr/share/webapps/cgit/cgit.cgi/" 
</VirtualHost> 

cgitrc의 일부입니다 http://hjemli.net/pipermail/cgit/2011-July/000235.html 가 여기 내 가상 호스트 구성입니다 : 내 구성을위한 템플릿으로 사용했다 http://cgit.mydomain.com

: 내가 좋아하는 하위 도메인에 cgit을 배포 할 :

css=/cgit.css 
logo=/cgit.png 
favicon=/favicon.ico 

모든 것이 잘 작동하지만, CSS 파일 및 파비콘이 작동하지 않으므로 cgit 웹 페이지가 끊어집니다. URL에 가면 http://cgit.mydomain.com/cgit.csscgitcgit.css이라는 리포가 없다고 알려줍니다. 보통 나는 내 브라우저에 cgit.css 파일을 보았다.

가능한 해결책은 /cgit/을 스크립트 별칭으로 사용하는 것입니다. 단, URL에 /cgit/ 조각을 갖고 싶지는 않습니다. http://cgit.osmocom.org에서 제대로 작동합니다.

답변

0

나는 왜 지금은 설치가 작동하는지주의를 기울이고 있습니다. 내 가상 호스트에 DocumentRoot "/usr/share/webapps/cgit/"을 추가 한 후 어제 작업을 중단했습니다. 오늘 내 cgit 웹 사이트를 살펴 보니 모든 것이 좋습니다! 캐시 문제 같은 것 같아요 ...

위 가상 호스트 설정이 작동합니다.

관련 문제