How do I build and deploy cloud services?

Source: Internet
Author: User
Keywords Azure azure fast Build
Tags .url access application browser click cloud cloud service cloud services

The Azure Management portal provides you with two ways to build and deploy a cloud service: Quick Build and custom build (customized create).

This article describes how to use the quick build method to build a new cloud service, and then use the upload (Update) feature to upload and deploy cloud service packs in Azure. If you use this approach, the Azure Admin portal provides easy links to meet all your requirements. If you are planning to deploy cloud services while building a cloud service, you can use custom build to perform both operations.

Note: If you plan to publish cloud services from Windows Team Infrastructure Services (TFS), use fast build, and then set up TFS publishing from the Quick Launch or dashboard. For more information, see "Using Team infrastructure services to continue delivering to azure," or looking at the Quick Start page for help.

Directory

Concept

Preparing the Application

Before you start

How to use fast build to build cloud services

How to upload a certificate for a cloud service

How to deploy cloud services

Concept

To deploy your application as a cloud service in Azure, you need the following three parts:

Note:

Service definition file: The Cloud service definition file (. csdef) defines the service model, including the number of roles.

Service profile: The Cloud service profile (. cscfg) provides the cloud services and the configuration settings for each role, including the number of role instances.

Service Packs: Service packs (. cspkg) contain application code and service definition files.

Preparing the Application

Before you can deploy cloud services, you must build cloud service packages (. cspkg) using your application code and build cloud service profiles (. cscfg). Each cloud service Pack contains application files and configurations. The service profile provides configuration settings.

The Azure SDK (software Development Kit) provides tools for preparing the necessary deployment files. You can install the SDK from the Azure download page and choose the language you like to use when you develop your application code.

If you have just contacted cloud services, you can download the sample Cloud service Pack (. cspkg) and service profile (. cscfg) from the Azure code example.

Before you export a service pack, three cloud service features require a special configuration:

If you want to deploy a cloud service that uses Secure Sockets Layer (SSL) for data encryption, configure your application for SSL. For more information, see How to Configure SSL certificates on HTTPS endpoints?

If you want to configure Remote Desktop Connection for a role instance, configure the role for Remote Desktop. For more information about preparing a service definition file for remote access, see "Setting up Remote Desktop connections for roles" Overview.

If you want to configure a detailed monitoring mechanism for cloud services, enable Azure diagnostics for cloud services. Minimum watch (the default monitoring level) uses performance counters collected from the host operating system of the role instance (virtual machine). Detailed monitoring is based on performance data within the role instance, and additional metrics are collected to enable further analysis of the issues that arise during application processing. To find out how to enable Azure diagnostics, see Enabling Diagnostics in Azure.

Before you start

If you have not installed the Azure SDK, click on the Install Azure SDK, open the Azure download page, and then download the SDK to choose the language you like to use when you write your code. (then you have the opportunity to do so.) )

If any role instances require a certificate, build the certificate. The cloud service requires a. pfx file with a private key. You can upload a certificate to Azure when building and deploying cloud services. To learn more about building certificates, see How to configure SSL certificates on HTTPS endpoints?

If you plan to deploy cloud services to GEO groups (affinity Group), build a geo group. You can use the GEO Group to deploy cloud services and other azure services to the same location in a zone. You can build geo-groups on the Geo-group page in the NX (network) area of the admin portal. To learn more, see Help on the Geo-group page.

How to use fast build to build cloud services

1. In the admin portal, click New (New), Cloud service (cloud services), and Quick Create (fast build).

  

2. In the URL, enter the subdomain name to be used in the public URL to access the cloud services in the production deployment environment. The URL format for the production deployment environment is: http://myURL.chinacloudapp.cn.

3. In the Region/affinity group (regional/GEO Group), select the geographic area or the GEO group in which you want to deploy the cloud services. If you want to deploy cloud services to an area in the same location as other azure services, select a Geo group.

Note: If you want to build a geo-group, open the NX (network) area of the Admin portal, click Affinity Groups (GEO Group), and then click Create New Affinity Group (build It) or create (build). You can use the geo-group built in the previous Azure Admin portal. You can also use the Azure service management API to build and manage geo groups. For more information, see GEO Group operations.

4. Click Create Cloud Service (build cloud services).

You can monitor the status of the process in the message area at the bottom of the window.

The Cloud Services (cloud service) area opens, displaying the new cloud service. The state becomes created (built), indicating that the cloud service build was completed successfully.

  

If any role in the cloud service requires a certificate for Secure Sockets Layer (SSL) data encryption and the certificate is not uploaded to Azure, you must upload the certificate before you can deploy the cloud service. After you upload the certificate, any Windows application running in the role instance can access the certificate.

How to upload a certificate for a cloud service

1. In the management portal, click Cloud Services (cloud service). Then click on the name of the cloud service to open the dashboard.

  

2. Click Certificates (certificate), open the Certificates (certificate) page, as shown below.

  

3. Click Add New certificate or upload (upload). Add a certificate (adds a certificate) opens.

  

4. In certificate file (certificate files), use Browse to select the certificate (. pfx file) that you want to use.

5. In password (password), enter the private key of the certificate.

6. Click OK (OK, hook-shaped symbol).

You can view the upload progress in the message area as shown below. When the upload is complete, the certificate is added to the table. In the message area, click the down arrow to close the message, or click X to delete the message.

  

You can deploy your cloud services from the dashboard or from the "Quick Launch".

How to deploy cloud services

1. In the management portal, click Cloud Services (cloud service). Then click on the name of the cloud service to open the dashboard.

2. Click Quick Start (the icon on the left of the dashboard) to open the Quick Launch page as shown below. (You can also use "upload" on the dashboard to deploy your cloud services.) )

  

3. If you have not installed the Azure SDK, click the Install Azure SDK, open the Azure download page, and then download the SDK and choose the language you like to use when you write your code.

On the download page, you can also install client libraries and source code to develop Web applications in Node.js, Java, PHP, and other languages that you can deploy as extensible Azure cloud services.

Note:

For previously built Cloud services (formerly Managed Services), you need to ensure that the guest operating system on the virtual machine (role instance) is compatible with the Azure SDK version that you install. For more information, please refer to the Azure SDK software release notes.

4. Click New Production Deployment (new production deployment environment) or new Staging deployment (new trial run deployment environment).

If you want to test your cloud services in Azure before deploying them to a production environment, you can deploy them to a pilot environment. In a pilot environment, the cloud service's globally unique identifier (GUID) identifies the cloud service (GUID.chinacloudapp.cn) in the URL. In a production environment, you will use a more user-friendly DNS prefix (such as myservice.chinacloudapp.cn) that you assign. If you are ready to publish a pilot cloud service to a production environment, you can use swap to redirect client requests to the production deployment environment.

After you choose to deploy the environment, Upload a Package (upload package) will open.

  

5. In Deployment name (deployment name), enter the name of the new deployment, such as MYCLOUDSERVICEV1.

6. In package (package), use browser (browse) to select the Service pack file (. cspkg) to use.

7. In revisit (configuration), use browser (browse) to select the service profile (. cscfg) to use.

8. If the cloud service will include any role that has only one instance, select Deploy Evan if one or more roles contain a single instance (even if the role contains an individual instance for deployment) check box to allow the deployment to continue.

If there are at least two instances of each role, Azure can only guarantee access to the cloud services during a period of 99.95% of the maintenance and service updates. If you want, you can add additional role instances to the scale (extended) page after you deploy the cloud service. For more information, refer to the service level agreement.

1. Click OK (OK, hook symbol) to start deploying cloud services.

You can monitor deployment status in the message area. Click the down arrow to hide the message.

  

Want to verify that the cloud services you deployed have been successfully completed.

1. Click Dashboard (instrument panel).

2. In quick glance (Quick View), click on the website URL, you can open your cloud service in the Web browser.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.