目前,Liferay 和 Apache 服务器是手动部署在服务器上的。
我正在尝试使用现有配置在另一台服务器上使用 Docker Compose 启动 httpd:2.4.39-alpine 和 liferay/dxp:7.1.10-security-dxp-17-202003-3-202006050913。
这些是我的配置:
- 码头工人-compose.yml
version: "3.8"
services:
mydxp:
build:
context: build/docker
networks:
- test-network
image: liferay/dxp:7.1.10-security-dxp-17-202003-3-202006050913
expose:
- "8282"
ports:
- "8282:8080"
myapache:
build:
context: docker-ref/apache
networks:
- test-network
image: httpd:2.4.39-alpine
expose:
- "8181"
ports:
- "8181:33090"
volumes:
- "./docker-ref/apache/htdocs:/usr/local/apache2/htdocs"
- "./docker-ref/apache/conf:/usr/local/apache2/conf"
networks:
test-network:
- docker-ref/apache/conf/httpd.conf
Listen 33090
- docker-ref/apache/conf/extra/httpd-vhosts-local.conf
<VirtualHost *:33090>
ServerName mydxp
RewriteEngine On
RewriteCond %{HTTP_HOST} ^127.0.0.1:8282$ [OR]
RewriteCond %{HTTP_HOST} ^127.0.0.1:8282$
# CUSTOM RewriteCond %{HTTPS} off
RewriteRule ^/(?)$ http://%{HTTP_HOST}/web/developer/home
# CUSTOM RequestHeader set X-Forwarded-Proto "https"
ProxyPreserveHost On
# Configuration for proxy page
ProxyPass /css !
ProxyPass /fonts/Open_Sans !
ProxyPass /fonts/FontAwesome !
ProxyPass /error_pages !
ProxyPass /img !
ProxyPass /disable http://%{HTTP_HOST}/error_pages/disable.html
ErrorDocument 502 /error_pages/502.html
ProxyPass / http://127.0.0.1:8282/
ProxyPassReverse / http://127.0.0.1:8282/
LimitRequestFieldSize 500000
LimitRequestLine 500000
</VirtualHost>
当这些容器启动时,使用 http://localhost:8282/ 返回 Liferay 的主页,但是当我点击 http://localhost:8181/ 时,我得到“503 Service Unavailable”
有没有办法检查/调试请求被 Apache 丢弃/拒绝的点?谢谢