web server 설치
>> yum install httpd
>> service httpd start
>> yum install php
>> yum install php-mysql
web server http 포트변경 (80 -> 8080)
>> vi /etc/httpd/conf/httpd.conf 수정
- Listen 8080
>> vi /etc/httpd/conf/httpd.conf 마지막에 추가
------------------------------------------------------
# Virtual hosts
Include conf/extra/httpd-vhosts.conf
------------------------------------------------------
>> mkdir /etc/httpd/conf/extra
>> vi /etc/httpd/conf/extra/httpd-vhosts.conf 생성 후 수정
------------------------------------------------------
<VirtualHost *:8080>
DocumentRoot "/var/www/html"
<Directory /var/www/html>
Options FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
require all granted
</Directory>
</VirtualHost>
------------------------------------------------------
web server https 설정 및 포트변경 (443 -> 8443)
>> yum install mod_ssl openssl
>> mkdir /etc/httpd/ssl; cd /etc/httpd/ssl
>> openssl genrsa -out server.key 2048
>> openssl req -new -key server.key -out server.csr
>> openssl x509 -req -days 365 -in server.csr -signkey server.key -out server.crt
>> vi /etc/httpd/conf/httpd.conf 추가
- Listen 8443
>> vi /etc/httpd/conf/extra/httpd-vhosts.conf 추가
------------------------------------------------------
<VirtualHost *:8443>
DocumentRoot "/var/www/html"
SSLEngine on
SSLCertificateFile /etc/httpd/ssl/server.crt
SSLCertificateKeyFile /etc/httpd/ssl/server.key
<Directory /var/www/html>
Options FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
require all granted
</Directory>
</VirtualHost>
------------------------------------------------------
'ETC' 카테고리의 다른 글
[CentOS] 버전별 설치 파일 (0) | 2016.03.31 |
---|---|
[CentOS] CentOS7 Minimal 기본 설정 (0) | 2016.03.31 |
[HTML5] DOCTYPE, 추가된태그, 사라진태그, 추가된input타입 (0) | 2013.08.22 |
DB 접속 드라이버 (0) | 2012.07.03 |
자바(java,jsp),자바스크립트(javascript) 에서 utf-8, euc-kr 간에 한글처리 (0) | 2012.06.13 |