Manage roles in Azure Cloud Services (extended support)

Note

This article applies to Azure Azure Cloud Services (extended support). Cloud Services (classic) is retired as of August 31, 2024. For more information, see Cloud services (classic) deployment model is retiring on August 31, 2024. For new development, we recommend that you use a newer service type designed for your specific purpose, such as Azure App Service, Azure Functions, or Azure Container Apps. For the latest list of available services, see Directory of Azure products.

After you have created your Azure Cloud Services (extended support) project, you can add new roles to it or remove existing roles from it. You can also import an existing project and convert it to a role. For example, you can import an ASP.NET web application and designate it as a web role.

Prerequisites

Adding a role to an Azure Cloud Services (extended support) project

The following steps guide you through adding a web or worker role to an Azure Cloud Services (extended support) project in Visual Studio.

  1. Create or open an Azure Cloud Services (extended support) project in Visual Studio.

  2. In Solution Explorer, expand the project node

  3. Right-click the Roles node to display the context menu. From the context menu, select Add, then select an existing web role or worker role from the current solution, or create a web or worker role project. You can also select an appropriate project, such as an ASP.NET web application project, and associate it with a role project.

    Screenshot that shows menu option to add a role to an Azure Cloud Services (extended support) project.

Removing a role from an Azure Cloud Services (extended support) project

The following steps guide you through removing a web or worker role from an Azure Cloud Services (extended support) project in Visual Studio.

  1. Create or open an Azure Cloud Services (extended support) project in Visual Studio.

  2. In Solution Explorer, expand the project node

  3. Expand the Roles node.

  4. Right-click the node you want to remove, and, from the context menu, select Remove.

    Screenshot that shows menu option to remove a role to an Azure Cloud Services (extended support) project.