c0micrage
c0micrage

Reputation: 1180

How to run Angular cli to https://localhost:4200 SSL mode

I am trying to figure out how to configure my Angular CLI environment to run in SSL HTTPS mode.

Right now, it runs in the regular http://localhost:4200 but it can't access the webAPI which is running https mode. I was able to get data from the webapi via google postman but not with my angular app.

In my start, I typed mmc and found my personal cert which shows as

localhost IIS Express Development

I read up on stackoverflow about changing the settings in a json file. I can't find the angular.json file. I found the package.json in the cli folder but when

how do I setup my angular app to run in https mode to access the data.

Right now, it just hangs.

Thanks.

Upvotes: 4

Views: 11727

Answers (1)

Fabio Carpinato
Fabio Carpinato

Reputation: 1181

You can run ng serve --ssl true

Upvotes: 12

Related Questions