<VirtualHost localhost2>
ServerAdmin postmaster@localhost2
DocumentRoot "/workspace/localhost2"
ServerName localhost2
ErrorLog "logs/localhost2.error.log"
CustomLog "logs/localhost2.access.log" combined
</VirtualHost>
<VirtualHost localhost>
ServerAdmin postmaster@localhost
DocumentRoot "/xampplite/htdocs"
ServerName localhost
ErrorLog "logs/localhost.error.log"
CustomLog "logs/localhost.access.log" combined
</VirtualHost>
위와 같이 로컬에서 http://localhost2/ 와 http://localhost/ 두가지 호스트를 돌리려고 합니다.
system32 폴더에서 어디론가 들어가 host 설정하는 데에 localhost2도 추가 해뒀고요.
문제는 localhost2라고 치든 localhost라고 치든 virtualhost의 맨 첫번째 설정이 모두 적용되고 있습니다. 즉 위와 같은 경우는 localhost2가 무조건 뜨고, virtualhost 설정 두개의 순서를 바꾸면 localhost가 뜨게 됩니다.
혹시 어디를 더 살펴봐야 할지 힌트 주시면 감사하겠습니다. ^^
ServerAdmin postmaster@localhost2
DocumentRoot "/workspace/localhost2"
ServerName localhost2
ErrorLog "logs/localhost2.error.log"
CustomLog "logs/localhost2.access.log" combined
</VirtualHost>
<VirtualHost localhost>
ServerAdmin postmaster@localhost
DocumentRoot "/xampplite/htdocs"
ServerName localhost
ErrorLog "logs/localhost.error.log"
CustomLog "logs/localhost.access.log" combined
</VirtualHost>
위와 같이 로컬에서 http://localhost2/ 와 http://localhost/ 두가지 호스트를 돌리려고 합니다.
system32 폴더에서 어디론가 들어가 host 설정하는 데에 localhost2도 추가 해뒀고요.
문제는 localhost2라고 치든 localhost라고 치든 virtualhost의 맨 첫번째 설정이 모두 적용되고 있습니다. 즉 위와 같은 경우는 localhost2가 무조건 뜨고, virtualhost 설정 두개의 순서를 바꾸면 localhost가 뜨게 됩니다.
혹시 어디를 더 살펴봐야 할지 힌트 주시면 감사하겠습니다. ^^
댓글 3개
게시글 목록
| 번호 | 제목 |
|---|---|
| 1731 | |
| 1726 |
개발자
오늘은 출석 포기할랍니다!
4
|
| 1721 |
개발자
성능 테스트 & 튜닝
4
|
| 1714 | |
| 1696 |
기획자
옥션 vs 11번가
17
|
| 1676 | |
| 1668 | |
| 1667 |
개발자
서버의 이상한 상황
|
| 1659 |
개발자
신입사원 면접
7
|
| 1653 | |
| 1651 | |
| 1634 | |
| 1631 | |
| 1626 | |
| 1620 |
디자이너
웹디자이너분들~
5
|
| 1583 | |
| 1580 | |
| 1577 | |
| 1564 | |
| 1559 | |
| 1551 | |
| 1545 | |
| 1542 |
디자이너
KBS뉴스티커가...
2
|
| 1539 | |
| 1510 | |
| 1490 | |
| 1482 |
디자이너
CS5를 살려고하는데...
7
|
| 1474 | |
| 1468 | |
| 1465 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기