Error while publishing an EF Core Angular app to Azure App service - sql-server

One year back I have worked for a project using the EF Core Angular app (.NET Core 2.1). Now we got some modification to the existing application. So when I try to execute the same application by changing the connection string in the appsettings.json file, it's working fine in local machine. But when I try to publish it in Azure app service it's giving some irrelevant error.
Note: The database is in an Azure VM earlier and now. But when we stop the VM and start the IP will be changed so we need to change only the connection string.
I tried installing all the run time SDK and host bundles. But it doesn't work. I wonder when it is working fine in local, Why it's not getting published in Azure.
Can somebody help me with this?

Congratulations that the issue is error is solved by #vamsi himself:
"I have fixed the issue by commenting the some of the lines in .csproj file."

Related

Getting error when create octopus release

I am using TFS as a CI tool and using Octopus to deploy my C# Web API project. Build artifacts package pushing and creating release successfully from TFS to octopus side, But When try to deploy for IIS in Assembly server, It's getting error as like this, Please check attached error log.
The line that's throwing that error is this one in Calamari. That function Assert-WebsiteExists only gets invoked when you try to do one of the following:
A) Deploy a Web Site in IIS under an already existing Web Application.
B) Deploy a Virtual Directory in IIS under an already existing Web Application.
Both of the above will fail if the parent Web Application (in your case WKLS.Mockservice) doesn't exist before you run that step, which is apparently what's happening in your case.
If you are trying to create the Web Application from that same Octopus deployment process, then you should use this step. If you want to use a Web Application that already exists, then perhaps you just typed the name incorrectly?

How to get BlogEngine.NET to run outside of a local environment?

I am trying to run BlogEngine.NET. It works fine locally in Visual Studio but whenever I publish it outside of my local computer none of the posts are showing up.
I think this is because none of the scripts or CSS are being loaded (the posts are done via AngularJS). I've made sure that the read and write permissions are allowed in IIS so I know that isn't the problem.
I believe that AngularJS isn't loading properly, as when I go to the admin panel the url returned with the 404 error is this:
8926/admin/%7B%7BSiteVars.RelativeWebRoot%7D%7Dadmin/#/dashboard
instead of:
8926/admin/#/dashboard
Even If I manually take out all of the %7B%7BSiteVars.RelativeWebRoot%7D%7Dadmin text, the posts still don't show up as they do locally which leads me to believe the posts are also tied to AngularJS as well.
Does anyone know how to fix this? This may not be a BlogEngine.NET problem as much as it is just a loading of Javascript and CSS problem inside of IIS
The documentation for my project is here.
BlogEngine.Net had moved to GitHub that is where the latest updates are at.
Best to go here:
https://github.com/rxtur/BlogEngine.NET
and try again with a fresh install.
I have a fresh install working with no issues here:
http://blogengine07.azurewebsites.net
Took a total of around 30 mins to it it 100% up and running, creating new web app service,database, change web.config, publish to Azure, and making some changes in settings.
What web host are you using to host your website?
You can also try Azure Web App Service for free here:
https://azure.microsoft.com/en-us/try/app-service/web/?language=cs
If you can get it to work there but not at your current web host then that points to a web server issue, since you are able to run it locally and on Azure.
Hope this helps.
Have a great Day!
Brian Keith Davis

Siverlight 4 Deployment : WCF RIA Services - “Not Found” Error Message

I have some issues deploying a Silverlight 4 application on a remote server machine. My application consist a Cosmopolitan theme (a master/child page model) that connected with 2 services to retrieve specific information.
The first service is pretty simple. It is an asmx service that sends back the User Logon name to the Silverlight application.
The second one is a LinqToSQL service that relay some information to some autocompletebox and search tool.
I have developed the application on my machine using a local SQL server. When I am testing locally with an address type like this one (http://localhost:4080), it is working perfectly. But when deploying on the server using the domain name, it is giving the error saying that the remote server returned an error: NotFound.
I followed and review every steps on of deployment but I still have a problem. I try by all means to find a solution to this problem. Of course go through the list of prerequisites provided on these sites:
http://msdn.microsoft.com/en-us/library/ff426912%28v=vs.91%29.aspx
First, I tried myself to deploy the application without having to disturb my network administrators that by installing the required dll’s in the Bin directory of my project. I have installed those 3 dll’s (System.ServiceModel.DomainServices.Server.dll, System.ServiceModel.DomainServices.Hosting.dll and Microsoft.ServiceModel.DomainServices.LinqToSql.dll). Of course, nothing worked.
I then ask the network administrator to install the WCF RIA services. Does he have to configure something other than installing the WCF RIA services? Is this service including the Microsoft.ServiceModel.DomainServices.LinqToSql.dll.
I suspect that my problem comes from a configurations file: ServiceReferences.ClientConfig or Web.config. But I have included the exact same information from the MSDN site of deployment so I do not see where my problem might be. Am I using the wrong technique to publish the project? I am publishing the site using the File System method and then after modifying the config file to point to the right domain name.
I am able to reach the services by typing the http://domainname/ MeritService1.svc. It is telling me that I can test with the svcutil.exe or slsvcutil.exe. Will I lose a lot of time testing this?
By the way, Fiddler does not give much information accept a 500 error code.
It seems that many developers have the same problem themselves but I do not know where to aim! Anybody have a clue?
Here are the specs:
Local machine: Windows XP,
Browser: IE8 with Silverlight
Server Machine: Windows 2003 with IIS 6, .NET 4.0 and WFC RIA installed.
The following link may be of some help
WCF RIA Services - “Not Found” Error Message

Cross Domain Silverlight Problem with localhost

I am currently looking into developing a silverlight app. I want to develop the app on my local machine for ease of development. I am using Apache Server on Windows which is hosting php. I am doing a WebClient DownloadStringASync to http://localhost/getData.php but the Silverlight webpage is running in visual studio asp server at http://localhost:54994/MySilverlight.aspx. I think because the silverlight app is running from the vs2010 server and I am making a call to my standard apache server it is having a cross domain problem. When the app is run the innerexception says System.Security.SecurityException at System.Net.Browser.BrowserHttpWebRequest.InternalEndGetResponse.
I have tried putting accesspolicy.xml file in the root of the asp server and the apache server but it still isn't fixing the problem. I know its not a problem with the code as if I run it from my website server and call the webclient request to the same domain it works fine.
Any help you can provide would be great thanks.
I've managed to solve the problem. I needed to have to crossdomain.xml and clientaccesspolicy.xml with the same code. For some reason if I only have one or the other it keeps on bringing up the security exception. As soon as both files in the root of the localhost directory of apache (i.e. in the root of htdocs) the silverlight app works fine

WCF Published service in IIS not working

My dev environment is Windows 7 and IIS 7.
i develop a silverlight 4 app that used Silverlight-Enabled WCF service. It is working true in IDE (Visual Studio 2010) but after published it in my IIS 7, service not working true.
clientconfig is true beacause the published service browse is working true.
WCF Service don't fail and does not error.
please help me.
Thanks
mSafdel
First thing to check is to ensure that the Silverlight app is pointing at the production service rather than still at the VS2010 one (ie, localhost:####). There's a few ways to handle this, like generating the WCF service call based on current server your app is coming from, getting the service live on production and updating the service reference to point at the new location, etc.
Another thing to be careful of is that when you move from the VS2010 environment to live you must ensure that your application and service can still access your database. If the user the service is using on IIS doesn't have permission or your connection string hasn't been updated, it sometimes seems like a WCF error (I think it pulls up server error 500 or the fun NotFound) but is actually your service unable to work with the database.
Otherwise, as Marek said more details are always helpful as a lot of things can go wrong in deployment/configuring WCF with Silverlight if you're not careful.

Resources