I am trying to set up an nginx server that sets certain parameters in a cookie when hit on a certain location.
I have the following configuration that puts the parameters in the cookie but the expiration does not work. This is my configuration:
server {
listen 8800 default_server;
include /etc/nginx/default.d/*.conf;
server_name test.net;
location /initial {
add_header Set-Cookie lcid=1043;
add_header Set-Cookie expires=60;
}
}
Based on my understanding, after 60 seconds of setting this cookie up the cookie should expire and get removed. However, it persists.
Is there anything wrong with this configuration?
Any help would be appreciated, Thanks!