반응형
참고로 맥북(M1)에 brew를 이용해서 apache2.4버전을 설치 하였다.
초기 개발 환경 설정은 아래 포스팅을 참고 바란다.
httpd.conf 파일 수정
vi /opt/homebrew/ect/httpd/httpd.conf
//모듈 확인
LoadModule negotiation_module lib/httpd/modules/mod_negotiation.so //주석해제
LoadModule rewrite_module lib/httpd/modules/mod_rewrite.so //주석해제
//<Driectory /> 또는 <Files /> 에서 Options 값에 MultiViews 설정
<Directory "설정할 디렉토리">
Options FollowSymLinks MultiViews //MultiViews 설정
AllowOverride All
Require all granted
</Directory>
//가상 호스트에 적용시
<VirtualHost *:80>
ServerName 도메인
ServerAdmin webmaster@localhost
DocumentRoot "도메인 root directory"
<Directory "도메인 root directory">
Options FollowSymLinks MultiViews //MultiViews 설정
AddType application/x-httpd-php .php .html .htm
AllowOverride All
Order allow,deny
allow from all
Require all granted
</Directory>
</VirtualHost>
negotiation_module 을 주석해제 하지 않아서 많은 시간을 소모했다. apache2 공식 사이트에서 해당 정보를 겨우 찾았다.
httpd를 재시작 하자
brew services restart httpd
반응형
'컴퓨터 > 서버구축' 카테고리의 다른 글
[서버 구축] 우분투 Ubuntu에 ssh 설치하기 (0) | 2022.05.05 |
---|---|
우분투 Ubuntu 설치하기. (0) | 2022.05.05 |
맥북 개발환경에서 SSL 사용하기 (0) | 2022.03.23 |
맥북(M1)에서 아파치 APACHE 가상호스트 설정하기. (0) | 2022.03.21 |
맥북(M1)에서 PHP / APACHE2 / MYSQL / phpmyadmin 설치하기. (0) | 2022.03.21 |
댓글