Nodejs production environment, is it necessary to use nginx as an agent?
What is the problem with using nodejs directly?
What is the problem with using nodejs directly
If your project is small and you have fewer customers, it may be really no problem.
Why use nginx
More flexible configuration, for example, I now want to redirect a special request to another address.
nginxCan be directly configured. But if you go directly
nodeThe program is external, then you must change the code and restart the server
80Port, read the official website all know,
nodeThe community is actually very, very not recommended for you to use.
nginxThe reverse agent is good
Record public log
There are really too many