azurewebsites/IIS 7 internal server when connecting to remote MySQL db using Yii 2 framework

对着背影说爱祢 提交于 2019-12-13 22:15:47

问题


I have a Azure WebApp + Services written in Yii and Yii 2 respectively. The database is MySQL db from ClearDB. i am hosting it on using the empty Php app.

Reference: https://blogs.msdn.microsoft.com/azureossds/2015/07/23/migrate-yii-framework-application-to-azure-web-app/

The webapp is working fine. In services when trying to connect to the ClearDB MySQL its working fine in XAMPP.

When use the same code in IIS 7 in my local (to simulate azurewebsites) i am receiving: i am getting error 500 (Internal server error) with message: SQLSTATE[HY000] [2002] No connection could be made because the target machine actively refused it. When i placed the same code on azurewebsites: i am getting error 500 (Internal server error) with no message,

Here is my project structure:

 Local: Xampp server
 htdocs/
       myapp/
             dashboard/            ---> this the website folder (Yii)
             modules/
                     v1/           -----> here are my yii2 services and controllers.

来源:https://stackoverflow.com/questions/40584609/azurewebsites-iis-7-internal-server-when-connecting-to-remote-mysql-db-using-yii

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!