Azure-Samples / application-gateway-dotnet-manage-application-gateways

Getting started on managing Application Gateways with backend pools in C#

Home Page:https://docs.microsoft.com/en-us/dotnet/azure

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

page_type languages products extensions
sample
csharp
azure
services platforms
virtual-network
dotnet

Getting started on managing Application Gateways with backend pools in C#

Azure network sample for managing application gateways.

  • CREATE an application gateway for load balancing HTTP/HTTPS requests to backend server pools of virtual machines This application gateway serves traffic for multiple domain names Routing Rule 1 Hostname 1 = None Backend server pool 1 = 4 virtual machines with IP addresses Backend server pool 1 settings = HTTP:8080 Front end port 1 = HTTP:80 Listener 1 = HTTP Routing rule 1 = HTTP listener 1 => backend server pool 1 (round-robin load distribution) Routing Rule 2 Hostname 2 = None Backend server pool 2 = 4 virtual machines with IP addresses Backend server pool 2 settings = HTTP:8080 Front end port 2 = HTTPS:443 Listener 2 = HTTPS Routing rule 2 = HTTPS listener 2 => backend server pool 2 (round-robin load distribution)
  • MODIFY the application gateway - re-configure the Routing Rule 1 for SSL offload and add a host name, www.Contoso.Com Change listener 1 from HTTP to HTTPS Add SSL certificate to the listener Update front end port 1 to HTTPS:1443 Add a host name, www.Contoso.Com Enable cookie-based affinity Modified Routing Rule 1 Hostname 1 = www.Contoso.Com Backend server pool 1 = 4 virtual machines with IP addresses Backend server pool 1 settings = HTTP:8080 Front end port 1 = HTTPS:1443 Listener 1 = HTTPS Routing rule 1 = HTTPS listener 1 => backend server pool 1 (round-robin load distribution)

Running this Sample

To run this sample:

Set the environment variable AZURE_AUTH_LOCATION with the full path for an auth file. See how to create an auth file.

git clone https://github.com/Azure-Samples/application-gateway-dotnet-manage-application-gateways.git

cd application-gateway-dotnet-manage-application-gateways

dotnet build

bin\Debug\net452\ManageApplicationGateway.exe

More information

Azure Management Libraries for C# Azure .Net Developer Center If you don't have a Microsoft Azure subscription you can get a FREE trial account here


This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.

About

Getting started on managing Application Gateways with backend pools in C#

https://docs.microsoft.com/en-us/dotnet/azure

License:MIT License


Languages

Language:C# 79.9%Language:JavaScript 8.1%Language:PowerShell 7.3%Language:HTML 4.0%Language:Shell 0.4%Language:CSS 0.2%Language:ASP.NET 0.0%