Share via

Azure static webapps deployed on https - virtual machine node api on http - site broken

nutissu 0 Reputation points
2023-08-22T18:57:46.8866667+00:00

I got a node api on an azure virtual server. It was working fine on http -- but when I recently added the static web app react - the react deployed as a https link -- and now refuses to try and connect to the http node -- I am unsure how to configure the azure virtual server to become https - and I think also I need to rejiggle the server.js file here in my node to take on 8080 and 443?

I have used pm2 to keep the nodejs alive when I exit putty - and its got a switch of sorts with .env variables

I'm not sure how to further adapt it or how you'd make various ssl certificates in azure virtual machines with apache or for nodejs. Tried following something like this.

https://stackoverflow.com/questions/5998694/how-to-create-an-https-server-in-node-js

Azure Virtual Machines
Azure Virtual Machines

An Azure service that is used to provision Windows and Linux virtual machines.


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.