-
-
Notifications
You must be signed in to change notification settings - Fork 85
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
zebra_session could be use in AWS ALB? #43
Comments
i'm sorry, i have no experience with any of those |
I believe that it should be able to be used in conjunction with the ALB. If you set a sticky session on your ALB, then it will automatically create a cookie with the specific server you were connecting to, therefore making it so you always return to that server (when the load balancer sees it). This package will write a session that is stored in the database instead of local file system making it so that even without persistent/sticky session it's available to any servers that reference it. |
I realize this is old, but I use this class with several AWS Elastic Beanstalk applications which use the AWS Application Load Balancer. To accomplish locking to IP in this environment, a couple changes need to be made to the class. First add a new private function for getting the end user's ip address:
Then update the places where $_SERVER['REMOTE_ADDR'] is used. Change this:
To this:
And change this:
To this:
This will now use the correct remote IP and lock_to_ip will work properly. |
this looks nice and I see no problem in adding this to the code as i don't think this should affect general usage of the library |
see #54 |
Hi, zebra_session could be use in AWS ALB and AWS WEB Searver Auto Scaling ?
AWS ALB will be not operate in stikey session mode.
The text was updated successfully, but these errors were encountered: