Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Get up and running with DuploCloud running inside a Microsoft Azure cloud environment; harness the power of generating application infrastructures.
This Quick Start tutorial shows you how to set up an end-to-end cloud deployment. You will create Azure infrastructure and tenants and, by the end of this tutorial, you can view a deployed sample web application.
Estimated time to complete tutorial: 90-100 minutes.
Creating Azure Agent Pools as shared resources across Tenants
So far you have created an , a , and a Now you need to create Agent Pools to serve computing and storage resources to your Tenants, using agents that monitor resource allocation.
Instead of managing each agent individually, agents are grouped into for maximum efficiency. You share Azure Agent Pools across workloads defined by the Tenants that you set up. Azure Agent Pools are scoped to a Host (Virtual Machine or VM) or a group of Hosts by . In this tutorial, you won't be creating specific Hosts, but you will create an Azure Agent Pool to which a group of VMs has already been defined by DuploCloud.
DuploCloud ensures that your application development platform conforms to Azure best practices. While you provide only high-level specifications, DuploCloud does the rest, configuring encryption, linking to managed identity, and logging you into a virtual Linux workstation to access Kubernetes constructs like , , and .
Estimated time to complete Step 3: 10 minutes.
Before creating Azure Agent Pools, verify that you accomplished the tasks in of this tutorial. In DuploCloud Portal, in the Administrator navigation group, confirm that you have:
An named NONPROD.
A named NONPROD.
A named DEV01
Selected Tenant DEV01 in the Tenant list box, at the top of the DuploCloud Portal.
In the DuploCloud Portal, navigate to Cloud Services -> Hosts.
Click the Azure Agent Pool tab.
Click Add. The Azure Agent Pool page displays.
From the table below, enter the values corresponding to the fields and options on the Azure Agent Pool page. Accept the defaults for fields that are not listed.
To run Windows container, K8WorkerOS should be set to Windows.
Click Add. After a few minutes, the Azure Agent Pool is created.
On the Azure Agent Pool page, verify that the created agent pool (with a Name generated by DuploCloud) has a Status of Succeeded.
Id
1
Instance Type
(4 CPU 16GB)
Creating a DuploCloud Tenant that segregates your workloads
Now that the Infrastructure and Plan exist and AKS has been enabled, create one or more Tenants that use the configuration DuploCloud created.
Tenants in DuploCloud are similar to projects or workspaces and have a subordinate relationship to the Infrastructure. Think of the Infrastructure as a virtual "house" (cloud), with Tenants conceptually "residing" in the Infrastructure performing specific workloads that you define. As Infrastructure is an abstraction of a Virtual Private Cloud. Tenants abstract the segregation created by a Kubernetes Namespace, although Kubernetes Namespaces are only one component that Tenants can contain.
In Azure, Microsoft cloud features such as Azure resource groups, Azure managed identity, Azure application security groups (ASG), and KMS keys are exposed in Tenants, which reference these feature configurations.
Estimated time to complete Step 2: 10 minutes.
DuploCloud customers often create at least two Tenants for their production and non-production cloud environments (Infrastructures).
For example:
Production Infrastructure
Pre-production Tenant - for preparing or reviewing production code
Production Tenant - for deploying tested code
Non-production Infrastructure
Development Tenant - for writing and reviewing code
Quality Assurance Tenant - for automated testing
In larger organizations, some customers create Tenants based on application environments, such as creating one Tenant for Data Science applications and another Tenant for web applications, and so on.
Tenants are sometimes created to isolate a single customer workload, allowing more granular performance monitoring, scaling flexibility, or tighter security. This is referred to as a single-Tenant setup.
Before creating a Tenant, verify that you accomplished the tasks in Step 1 of this tutorial. Using the DuploCloud Portal, confirm that:
An Infrastructure and Plan exist, both with the name NONPROD.
The NONPROD infrastructure has Azure Kubernetes Service (AKS) Enabled.
Create a Tenant for your Infrastructure and Plan:
In the DuploCloud Portal, navigate to Administrator -> Tenants.
Click Add. The Create a Tenant pane displays.
Enter dev01 in the Name field.
Select the Plan that you created in the previous step (NONPROD).
Click Create.
Navigate to Administrator -> Tenants and verify that the dev01 Tenant displays in the list.
Navigate to Administrator -> Infrastructure and select dev01 from the Tenant list box at the top left in the DuploCloud Portal. The NONPROD Infrastructure appears in the list of Infrastructures, indicating that the dev01 Tenant is associated with Infrastructure NONPROD.
Create a DuploCloud Service for application deployment
With all of the core components of your Duplocloud platform configured, enabled, and running, you're ready to deploy applications with Azure, using AKS and Kubernetes.
In order to deploy applications, you must first create a DuploCloud Service to connect to the Docker containers and images where your application code exists. Once you create a service from the DuploCloud Portal, you can also perform tasks that you might perform when working with a Kubernetes service. For example, you can view container logs, container state, and container shell, as well as get access to kubectl
, which allows you to work directly with Kubernetes constructs such as Pods.
In this step, we create a service to connect a Docker container image with code that displays text on a web page. The Docker container and image name is nginx:latest. nginx is the image name and :latest indicates that the latest version of that image will be used.
Estimated time to complete Step 4: 15 minutes.
See the Docker documentation for an overview of containers and images.
Before creating your DuploCloud Service, ensure that:
All previous steps in this tutorial to create an Infrastructure and Plan, Tenant, Host, and Azure Agent Pool are complete.
The AKS Kubernetes cluster is enabled.
Tenant DEV01 is selected in the Tenant list box, at the top of the DuploCloud Portal.
In the DuploCloud Portal, navigate to Kubernetes -> Services.
Click Add. The Add Service page displays.
In the Service Name field, enter nginx-service.
Specify the Docker image that you use to run the application. In the Docker Image field, enter nginx:latest.
Click Next, accepting all other defaults. The Advanced Options page displays.
Scroll down if needed and click Create.
After a few minutes, the Service initializes and starts up. Shortly afterward, you can see the service and the containers running.
Creating the DuploCloud Infrastructure and a Plan
Each DuploCloud Infrastructure is a connection to a unique Virtual Private Cloud (VPC) network that resides in a region that can host Kubernetes clusters. An Infrastructure can reside On-Premises (On-Prem) or in a Public Cloud.
After you supply a few basic inputs DuploCloud creates an Infrastructure for you, within Azure and within DuploCloud, with a few clicks. Behind the scenes, DuploCloud does a lot with what little you supply—generating subnets, NAT gateway, routes, and a cluster in the region.
With the Infrastructure as your foundation, you can customize an extensible, versatile Platform Engineering development environment by adding Tenants, Hosts, Services, and more.
Estimated time to complete Step 1: 40 minutes. Much of this time is consumed by DuploCloud's creation of the Infrastructure and enabling your AKS cluster with Kubernetes.
Before starting this tutorial:
Learn more about DuploCloud Infrastructures, Plans, and Tenants.
Reference the Access Control documentation to create User IDs with the Administrator role. In order to perform the tasks in this tutorial, you must have Administrator privileges.
In the DuploCloud Portal, navigate to Administrator -> Infrastructure.
Click Add. The Add Infrastructure page displays.
From the table below, enter the values that correspond to the fields on the Add Infrastructure page. Accept all other default values for fields not specified.
Click Create to create the Infrastructure. It may take up to half an hour to create the Infrastructure. When creation completes, a status of Complete displays.
Name
nonprod
Subscription
YOUR_AZURE_SUBSCRIPTION_NAME
VNET CIDR
10.23.0.0/16
Subnet CIDR
10.23.0.0/20
Cloud
Azure
Region
YOUR_GEOGRAPHIC_REGION
In the DuploCloud Portal, navigate to Administrator -> Infrastructure.
Select the Infrastructure you created.
Click the Kubernetes tab.
Select the Click Here link. The Configure AKS Cluster pane displays.
Enter a name in the Cluster name field.
Select the node VM size from Node VM Size list box.
To use Windows containers, Network plugin should be set to Azure. This config will make Kubernetes pods to get IP assigned from Subnets address space, Make sure Infrastructure default subnet use /18 for network prefix. At least /20 should be used or IP Address space might run out.
Click Create. It may take some time to configure the cluster. The Kubernetes card on the Infrastructure page shows Enabled when the cluster is complete. You can also monitor progress using the Kubernetes tab.
Every DuploCloud Infrastructure generates a Plan. Plans are sets of templates that are used to configure the Tenants or workspaces, in your Infrastructure. You will set up Tenants in the next tutorial step.
Before proceeding, confirm that a Plan exists that corresponds to your newly created Infrastructure.
In the DuploCloud Portal, navigate to Administrator -> Plans. The Plans page displays.
Verify that a Plan exists with the name NONPROD, the name that you gave to the Infrastructure you created.
DuploCloud begins creating and configuring an AKS cluster using Kubernetes. You receive an alert message when the Infrastructure has been updated.
You previously verified that your Infrastructure and Plan were created. Now, verify that AKS is Enabled before proceeding to Create a Tenant.
From the Infrastructure page, select the Infrastructure (NONPROD) that you created. When AKS has been Enabled, details are listed in the Kubernetes tab on the Infrastructure page. This page also displays the Enabled status on the Kubernetes card.
Test the application to ensure you get the results you expect
You can test the sample web page application directly from the VIEWWEBSITE Ingress .
Estimated time to complete Step 6 and finish tutorial: 10 minutes.
Before testing your application, ensure that:
Previous steps in this tutorial to create an , , , , and are complete.
is enabled.
Tenant dev01 is selected in the Tenant list box, at the top of the DuploCloud Portal.
.
You for your DuploCloud Service to listen on port 80, enabled the , and configured a Load Balancer Listener that uses .
Display the web page that the application creates:
In the DuploCloud Portal, navigate to Kubernetes -> Ingress.
Select the VIEWWEBSITE Ingress from the Name column.
Click the Configuration tab.
In the Application Gateway IP card, copy the displayed IP address to your clipboard. In this example, the IP address is 20.84.11.154.
Open a web browser and paste the copied IP address in your browser's URL field.
Press Enter. Your application runs and your web page renders as shown below. Congratulations! You just launched your first web service with Azure on DuploCloud!
In this tutorial, your objective was to create a cloud environment to deploy an application for testing purposes, and to understand how the various components of DuploCloud work together.
The application rendered a simple web page with text, coded in JavaScript, from software application code residing in a Docker container. You can use this same procedure to deploy much more complex cloud applications.
In the previous steps, you:
In this tutorial, you created many artifacts for testing purposes. When you are ready, clean them up so that another person can run this tutorial from the start, using the same names for Infrastructure and Tenant.
The NONPROD Infrastructure is deleted and you have completed the clean-up of your test environment.
Thanks for completing this tutorial and proceed to the next section to learn more about using DuploCloud with Microsoft Azure.
named NONPROD, a Virtual Private Cloud instance, backed by an AKS-enabled Kubernetes cluster.
named dev01 in Infrastructure NONPROD. While generating the Infrastructure, DuploCloud created a set of templates () to configure multiple Azure and Kubernetes components needed for your environment.
backed by pre-existing hosts (VMs), so that your application has storage resources with which to run.
to connect the Docker containers and associated images, in which your application code resides, to the DuploCloud Tenant environment.
and a Kubernetes Node Port to expose your application via ports and backend network configurations. You enabled an Azure application gateway and created a Kubernetes Ingress to communicate with the node port and the AKS-enabled Kubernetes cluster in the Infrastructure.
as expected by testing the IP address exposed by the Kubernetes Ingress.
To delete the dev01 tenant and then return to this page. As you learned, the Tenant segregates all work in one isolated environment, so deleting the Tenant that you created cleans up most of your artifacts.
Finish by deleting the NONPROD Infrastructure. In the DuploCloud Portal, navigate to Administrator -> Infrastructure. Click the Action menu icon () for the NONPROD row and select Delete.
Create a load balancer to access your application
Now that your DuploCloud Service is running, you have a mechanism to expose the containers and images in which your application resides. But because your containers are running inside a private network, you also need a load balancer to listen on the correct ports in order to access the application.
In this step, we add a Load Balancer Listener to complete this network configuration.
Estimated time to complete Step 5: 20 minutes.
Before creating your DuploCloud load balancer, ensure that:
All previous steps in this tutorial to create an Infrastructure and Plan, Tenant, Azure Agent Pool, and Service are complete.
AKS Kubernetes cluster is enabled.
dev01 is selected in the Tenant list box, at the top of the DuploCloud Portal.
Add a load balancer for your running service that listens on port 80:
In the DuploCloud Portal, navigate to Kubernetes -> Services.
On the Services page, select the nginx-service you started when creating a service in the previous step.
Click the Load Balancers tab.
Click the Configure Load Balancer link. The Add Load Balancer Listener pane displays.
Select K8S Node Port from the Select Type list box.
Enter 80 in the Container port field.
Enter 30008 in the External port field.
Type / (forward-slash) in the Health Check field to indicate that the cluster we want Kubernetes to perform Health Checks on is located at the root
level.
Select TCP from the Backend Protocol list box.
Click Add. The Load Balancer is created and started. After a few minutes, the LB Status card displays a status of Ready, indicating that the Load Balancer is ready for use.
When we created the Load Balancer Listener, we used the K8S Node Port type, which leverages the capabilities of the Kubernetes Ingress object.
Ingress is an entry point that front-ends multiple services in a cluster. It can be defined as a collection of routing rules that governs how external users access services running inside a Kubernetes cluster. One of the greatest benefits of Ingress is its ability to secure the network traffic to your application. With Ingress, you can define a TLS private key and certificates by leveraging Kubernetes Secrets, instead of directly defining TLS details in the Ingress resource.
To use Ingress, you first enable the Kubernetes Ingress Controller to open the application gateway for Ingress.
In the DuploCloud Portal, navigate to Administrator -> Infrastructure.
Select your Infrastructure from the Name column.
Click the Settings tab.
Click Add. The Infra-Set Custom Data pane displays.
In the Setting Name field, select Enable App Gateway Ingress Controller.
Click Enable.
Click Set. In the Settings tab, the Enable App Gateway Ingress Controller setting now contains the true in the Value column.
Now that your gateway is established and opened, you add Kubernetes Ingress to expose the backend HTTP routes outside the cluster to your service.
The Ingress object communicates with the Kubernetes NodePort that your Load Balancer Listener uses. Ingress objects are flexible constructs in Kubernetes, and their use here is an example of how DuploCloud leverages the power of Kubernetes constructs while abstracting away their native complexity. To manually create these components (and maintain them) in Kubernetes, takes a significant amount of developer time.
In the DuploCloud Portal, navigate to Kubernetes -> Ingress.
Click Add. The Add Kubernetes Ingress page displays.
In the Ingress Name field, type viewwebsite.
In the Ingress Controller list box, select azure-application-gateway.
In the Visibility list box, select Public.
Click Add Rule. The Add Ingress Rule pane displays.
In the Path field, type / (forward-slash).
In the Service Name field, select nginx-service:80.
Click Add Rule to add the rule and to close the Add Ingress Rule pane. You should be back to viewing the Add Kubernetes Ingress page.
On the Add Kubernetes Ingress page, click Add to add Ingress. On the Ingress page, the VIEWWEBSITE Ingress that you defined, with an Ingress Class of azure-application-gateway, displays.
Before you proceed to the final step and run your application, ensure that you:
Configured a Load Balancer Listener that uses K8S Node Port.
Enabled the App Gateway Ingress Controller.
Defined an Ingress and a rule for your DuploCloud Service to listen on port 80.