0

We have an Angular 7 application on one git repository and an ASP.NET Core 2.2 Web API on another git repository. We use Azure pipelines to deploy both repos into an Azure App Service.

I have successfully been able to configure the Web API to deploy to the root directory and the Angular client into a wwwrooot sub directory.

However, in order to achieve this I need to configure the wwwroot sub-directory as an application, which makes the application fail with HTTP 404. Once I change the settings to be "Directory" in the Azure app service, everything works as normal.

Is there a way to have the Angular pipeline deploy to the sub-directory while configured as Directory instead of Application?

enter image description here

Thank you,

Fernando
  • 614
  • 1
  • 9
  • 20
  • I dont think so. And I also don't think this is a good idea. The API and the Angular app are both their own app and should each have a dedicated app service. This way, you can scale each separately as needed. – DrDoomPDX Jul 05 '19 at 13:36
  • Thank you. VS deploys both this way. So its not unusual. – Fernando Jul 06 '19 at 02:19

1 Answers1

0

I solved my issue from within the pipelines. Following this post (VSTS build with multiple repos) I added the FE artifacts to the pipeline and simply copy it's dist contents to the wwwroot folder of the API build folder. Then I simply deploy everything to App Services and now both the API and Angular App are deployed on the same server and working.

Hope this helps someone.

Fernando
  • 614
  • 1
  • 9
  • 20