How to deploy multiple web roles in Azure

I looked through several articles and questions SO -,, and this (and many others)

However, none of them serves my problem. I would like to deploy two roles in one cloud service. I tried to deploy the same, but found that it works, while other roles in the web role - Internet Explorer cannot display the webpage / connection timeout in firefox.

Here is what I have tried so far:

I have two web roles (application and service) when I deployed the application or service to a cloud service, for example. http://xxxx.cloudapp.net , it works great.

But when I tried to deploy both the application on port 8080 and the service on port 80 at http://xxxx.cloudapp.net , and tried to view - http://xxxx.cloudapp.net , it displays the service page.

While while viewing an application using - http://xxxx.cloudapp.net:8080 , it throws an error - Internet Explorer cannot display the timeout of the webpage / connection in firefox.

But my application works fine when the application is open on port 80.

Here is the ServiceDefinition file: -

<ServiceDefinition name="AppServiceAzure" xmlns="http://schemas.microsoft.com/ServiceHosting/2008/10/ServiceDefinition" schemaVersion="2013-03.2.0"> <WebRole name="MyService" vmsize="Small"> <Sites> <Site name="Web"> <Bindings> <Binding name="Endpoint1" endpointName="Endpoint1" /> </Bindings> </Site> </Sites> <Endpoints> <InputEndpoint name="Endpoint1" protocol="http" port="80" /> </Endpoints> <Imports> <Import moduleName="Diagnostics" /> </Imports> <Certificates> <Certificate name="mycert" storeLocation="LocalMachine" storeName="My" /> </Certificates> </WebRole> <WebRole name="MyApp" vmsize="Small"> <Sites> <Site name="Web"> <Bindings> <Binding name="Endpoint1" endpointName="Endpoint1" /> </Bindings> </Site> </Sites> <Endpoints> <InputEndpoint name="Endpoint1" protocol="http" port="8080" /> </Endpoints> <Imports> <Import moduleName="Diagnostics" /> </Imports> <Certificates> <Certificate name="mycert" storeLocation="LocalMachine" storeName="My" /> </Certificates> </WebRole> </ServiceDefinition> 

What am I missing here?

+4
source share
1 answer

Each instance of Windows Azure Compute represents a virtual server in any of the following roles.

 Windows Azure Compute instance | |_______[front-end] web server (Web role) | | |_____Site1 | | |_____Site2 | | |_____Site3 etc. 

or

 | | | |_______back-end/.NET] application server (Worker role) or | | | |_______VM 

I offer two approaches: 1) create several sites in one role (you will get different endpoints) 2) Or deploy one webrole before placing and another role in production . (again you will get different endpoints)

0
source

Source: https://habr.com/ru/post/1490629/


All Articles