1
votes

We currently have an Azure Cloud Service running one web role and two worker roles. As of now the web role consists of both a WebApi backend and a client web application running AngularJS.

We are now looking into the possibility to split the web role in two. One serving WebApi for the backend and one role just for the client application.

I've tried to have two web roles in the same cloud service, but it doesn't seem possible to have two roles bound to the same port (SSL/443) because they share the same public ip address.

I've seen solutions to have to sites in the same web role using host headers to differentiate them, but this isn't what we want.

What we want is;

Webrole1 - AngularJS client app

Webrole2 - WebAPI (SSL/443)

Is there any way of accomplishing this?

1

1 Answers

-1
votes

You may have several web roles in the same cloud service. However, you won't be able to use the same ports. You'd need to come up with different port mappings outside of 80/443, since the external-facing endpoints are tied to a specific role.

The only way you can take the host header approach is if you keep your functionality within a single role, as you currently have it.