Hello Support,
I have deployed the Server project on Azure and also updated the API URL in client project under src/assets/appconfig.Json file. Now I want to deploy the client project on Azure also using the same WPI Url. If I am running the client application on local browser under localhost:4200 after starting the npm start then it is running correctly, but I amn't able to deploy the application on Azure server. Even I followed the below article, not able to find out the solution. I might be doing some mistakes in the URLs. Could you please help me to resolve this issue. As I want to deploy both as different projects.
#2285@10c752de-7894-4f60-b1bb-c7d1279f2c00
Note: I am using VS 2015 Update 3
Thanks Harsh
5 Answer(s)
-
0
Hi,
I think angular-cli removed build commands from it's homepage.
Basically, you need to do this:
- Open a command prompt and navigate to root of angular project (angular folder in your solution)
- then run "ng build -prod" and it will publish client app to dist folder.
- Then transfer files under dist folder to your azure website for angular client side app. Also transfer web.config file under angular folder to azure website, otherwise you will have some problems.
- After that configure appconfig.json according to your website addresses both for host and client.
Then it should work.
Please let us know if it does not.
Thanks.
-
0
Thanks for Reply,
It's almost working, but having one issue. Ít is not connecting database API. I have updated appconfig.json and also put the web.config file from the angular folder on Azure. Please guide me, may I miss something.
Thanks
-
0
please check the issue <a class="postlink" href="https://www.screencast.com/t/XHdrxlAGEe">https://www.screencast.com/t/XHdrxlAGEe</a>
-
0
Support,
Application is working correctly now, I needed to deply the host application again.
Thanks
-
0
Thanks for your quick feedback :)