worker_processes 1;
error_log stderr;
pid nginx.pid;
daemon off;
types_hash_max_size 2048;

events {
	worker_connections 768;
}

http {
	include mime.types;
	server {
		listen <%= ENV['PORT'] %>;
		server_name  _;
		root <%= ENV.fetch('root', '/app/www') %>;
		index index.html;
	}
}

worker_processes 1;
error_log stderr;
pid nginx.pid;
daemon off;

events {
	worker_connections 768;
}

http {
	types_hash_max_size 2048;
	include mime.types;
	server {
		listen <%= ENV['PORT'] %>;
		server_name  _;
		root <%= ENV.fetch('root', '/app/www') %>;
		index index.html;
	}
}

Move types_hash_max_size to the http context
Move types_hash_max_size to the http context