英文:
How to host go application on dedicated server, without using google app engine
问题
可以将Go应用程序部署在Apache或Nginx服务器上吗?
英文:
Is it possible to host a go application on apache/nginx server ?
答案1
得分: 9
当然可以。你可以直接使用Go内置的Web服务器(非常强大),或者选择在nginx/Apache反向代理后面运行。
我将我的Go应用程序放在nginx后面,并使用supervisord来管理日志记录、重启和管理Go应用程序。
可以参考这两个答案获取更多详细信息:https://stackoverflow.com/questions/17440415/golang-production-web-application-configuration/17461472#17461472 和 https://stackoverflow.com/questions/17776584/webserver-for-go-golang-webservices-using-nginx-or-not/17777630#17777630
英文:
Of course. You can use Go's built in web-server directly (which is very capable), or sit behind a nginx/Apache reverse proxy if you so wish.
I run my Go application behind nginx, and use supervisord to manage logging, restarting and managing my Go application.
Take a look at these two answers for some more details: https://stackoverflow.com/questions/17440415/golang-production-web-application-configuration/17461472#17461472 and https://stackoverflow.com/questions/17776584/webserver-for-go-golang-webservices-using-nginx-or-not/17777630#17777630
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论