server
{
        listen |IP|:|PORT_80|;
        |MULTI_IP|
        server_name |POINTER| www.|POINTER|;
        rewrite     ^ http://www.|DOMAIN|$request_uri? permanent;
}

|*if HAVE_SSL="1"|
server
{
	listen |IP|:|PORT_443| ssl|SPACE_HTTP2|;
	|MULTI_IP_SSL|
	server_name |POINTER| www.|POINTER|;
	rewrite     ^ http://www.|DOMAIN|$request_uri? permanent;
		
	ssl                  on;
	ssl_certificate      |CERT|;
	ssl_certificate_key  |KEY|;
}
|*endif|