--Connect with https when running Spring Boot on Elastic Beanstalk's Java platform
--Https listener set in LB --The following communication paths
LB(443) <-> Nginx(80) <-> Spring Boot(5000)
--Set the following in application.properties
server.tomcat.remote-ip-header=x-forwarded-for
server.tomcat.protocol-header=x-forwarded-proto
--For environment variables, set as follows
SERVER_TOMCAT_REMOTE_IP_HEADER=x-forwarded-for
SERVER_TOMCAT_PROTOCOL_HEADER=x-forwarded-proto
--server.tomcat.remote-ip-header
is for remote IP address, so it works without setting
--The following AWS manual describes the header
--HTTP Headers and Classic Load Balancer
-Details of Elastic Load Balancing
--It becomes http when redirecting --Page redirect after authentication --PRG pages
--When accessed via https, Set-Cookie
has Secure
.
--Redirect http traffic to https
--How do I use ELB's Classic Load Balancer to redirect HTTP traffic to HTTPS?
-Application Load Balancer Listener
-[New function] No need to implement on Web server! You can now redirect with just ALB!
end.
Recommended Posts