server {
	listen 80;
	server_name mail.especificosba.com.ar;
	rewrite ^ https://mail.especificosba.com.ar permanent;
}
server {
	listen   443 ssl; ## listen for ipv4; this line is default and implied
	include ssl;

	#root /usr/share/apache2/roundcubemail/;
	root /var/www/r/;
	index index.php;

	server_name mail.*;
	location ~ \.php($|/)
	{
		include		fastcgi_params;
		fastcgi_pass	unix:/var/run/php5-fpm.sock;
		fastcgi_index	index.php;
		fastcgi_keep_conn on;
		fastcgi_split_path_info       ^(.+\.php)(.*)$;
		fastcgi_param PATH_INFO       $fastcgi_path_info;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
		fastcgi_param	SERVER_NAME	$http_host;
		fastcgi_ignore_client_abort	on;
		fastcgi_intercept_errors	off;
	}

	location / {
		# First attempt to serve request as file, then
		# as directory, then fall back to displaying a 404.
		try_files $uri $uri/ /index.html;
		# Uncomment to enable naxsi on this location
		# include /etc/nginx/naxsi.rules
	}


	# deny access to .htaccess files, if Apache's document root
	# concurs with nginx's one
	#
	location ~ /\.ht {
		deny all;
	}
}

