개발/서버
Linux Apache Tomcat 연동 (동일 서버 설정)
설이주인
2024. 5. 11. 21:11
httpd.conf
cd /etc/httpd/conf
ServerName 127.0.0.1:8080
<Directory />
AllowOverride none
# Require all denied
Require all granted
</Directory>
proxy.conf
cd /etc/httpd/conf.d
<VirtualHost *:80>
ServerName localhost
ErrorLog logs/http-error_log
CustomLog logs/http-access_log common
ProxyRequests Off
ProxyPreserveHost On
<Proxy *>
Order deny,allow
Allow from all
</Proxy>
ProxyPass / http://localhost:8080/
ProxyPassReverse / http://localhost:8080/
<Location />
Order allow,deny
Allow from all
</Location>
# => SSL HTTPS 리다이렉트 설정 후 주석 해제
#RewriteEngine On
#RewriteCond %{HTTPS} !on
#RewriteRule ^(.*)$ https://%{HTTP_HOST}$1 [R=301,L]
</VirtualHost>