아마존 ELB (> 8080 80> 8080 443-) -> 아파치 서버 (포트 8080)아파치 리디렉션 (후행 슬래시 문제)
내 아파치 서버의/var/www/html 루트로 가지고있다./var/www/html/customer는/mnt/content/customer에 대한 심볼릭 링크입니다.
http://company.com/customer redirects to http://company.com/customer/
https://company.com/customer redirects to http://company.com/customer/
내가 원하는 : //company.com/customer/
참고 HTTP에 후행 슬래시 및 HTTPS : https://company.com/customer이 HTTPS로 리디렉션합니다. https에 머물고 싶습니다.
나는 내 /mnt/content/customer/.htaccess에서 다음을 시도했다 :
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} -d
RewriteCond %{REQUEST_URI} !(.*)/$
RewriteRule ^(.*)$ https://company.com/$1/ [L]
난 아직 HTTP로 리디렉션. 내 기본 파일은 index.html입니다. 나는 그물에 대해 다른 제안을 시도했지만 뭔가 빠졌습니다.
도움을 주시면 감사하겠습니다.
은 https://company.com//로 리디렉션됩니다. 끝의 두 개의 슬래시에 유의하십시오. https://company.com/customer/가 필요합니다. 무엇이 누락 되었습니까? – magd1
수정 된 답변을 지금 사용해보십시오. – anubhava
"페이지가 제대로 리디렉션되지 않습니다. Firefox가 서버가이 주소에 대한 요청을 완료되지 않는 방식으로 리디렉션 중임을 감지했습니다." – magd1