简体   繁体   中英

i am trying to deploy ASP.NET CORE API Version 3.1 to local IIS Hostiing but can not connect to SQL Server

I have deployed asp .net core api app on local IIS Manger when i call action that need to retrieve data from sql database does not work,i opned C:\inetpub\logs\LogFiles\W3SVC3 found 404 not found error, i found another error in my log as Login failed for user 'IIS APPPOOL\service', but when i call another action that returns local data it works fine here is my connection string

"ConnectionStrings": {

    "ERPConnection": "server=.; user Id=ssa;password=12345678;database=dbname;trusted_connection=true;MultipleActiveResultSets=true"
},

and my application pool is not manged code: 在此处输入图像描述

Where is your SQL Server instance hosted? If its localhost try using the full local host domain name.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM