proxy_read_timeout 300; proxy_connect_timeout 300; proxy_send_timeout 300; map $http_accept_language $header_lang { default en-US; ~*^en-US en-US; ~*^en en-US; ~*^ar ar; ~*^cs cs; ~*^de de; ~*^es es; ~*^fa fa; ~*^fr fr; ~*^ja ja; ~*^ka ka; ~*^nl nl; ~*^nn nn; ~*^pt pt; ~*^sl sl; ~*^sv sv; ~*^tr tr; ~*^uk uk; ~*^vi vi; ~*^zh zh; } map $cookie_lang $lang { default $header_lang; ~*^en-US en-US; ~*^en en-US; ~*^ar ar; ~*^cs cs; ~*^de de; ~*^es es; ~*^fa fa; ~*^fr fr; ~*^ja ja; ~*^ka ka; ~*^nl nl; ~*^nn nn; ~*^pt pt; ~*^sl sl; ~*^sv sv; ~*^tr tr; ~*^uk uk; ~*^vi vi; ~*^zh zh; }