This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Signing into azure with principal account | |
$clientID = "<--client-id-->" | |
$key= "<--secret-key-->" | |
$SecurePassword = $key | ConvertTo-SecureString -AsPlainText -Force | |
$cred = new-object -typename System.Management.Automation.PSCredential ` -argumentlist $clientID, $SecurePassword | |
Add-AzureRmAccount -Credential $cred -Tenant "<--tenant-id-->" -ServicePrincipal | |
# Selecting Subscription | |
Select-AzureRmSubscription "<--subscription-id-->" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Signing into azure with principal account | |
$clientID = "<--client-id-->" | |
$key= "<--secret-key-->" | |
$SecurePassword = $key | ConvertTo-SecureString -AsPlainText -Force | |
$cred = new-object -typename System.Management.Automation.PSCredential ` -argumentlist $clientID, $SecurePassword | |
Add-AzureRmAccount -Credential $cred -Tenant "<--tenant-id-->" -ServicePrincipal | |
# Selecting Subscription | |
Select-AzureRmSubscription "<--subscription-id-->" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Create Traffic Manager API Profile | |
resource "azurerm_traffic_manager_profile" "traffic-manager" { | |
name = "tm-global-contoso-${var.environment}" | |
resource_group_name = "${azurerm_resource_group.resource-group-global.name}" | |
traffic_routing_method = "Performance" | |
dns_config { | |
relative_name = "tm-global-contoso-${var.environment}" | |
ttl = 300 | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Create Application Gateways | |
resource "azurerm_application_gateway" "application-gateway-west" { | |
name = "ag-westus-contoso-${var.environment}" | |
resource_group_name = "${azurerm_resource_group.resource-group-westus.name}" | |
location = "${azurerm_resource_group.resource-group-westus.location}" | |
sku { | |
name = "WAF_Medium" | |
tier = "WAF" | |
capacity = 2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Create Vnets | |
resource "azurerm_virtual_network" "vnet_west" { | |
name = "vnet-westus-contoso-${var.environment}" | |
resource_group_name = "${azurerm_resource_group.resource-group-westus.name}" | |
location = "${azurerm_resource_group.resource-group-westus.location}" | |
address_space = ["10.0.0.0/16"] | |
} | |
resource "azurerm_virtual_network" "vnet_east" { | |
name = "vnet-eastus-contoso-${var.environment}" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Create App Service Plans | |
resource "azurerm_app_service_plan" "app-service-plan-westus" { | |
name = "asp-westus-contoso-${var.environment}" | |
location = "${azurerm_resource_group.resource-group-westus.location}" | |
resource_group_name = "${azurerm_resource_group.resource-group-westus.name}" | |
sku { | |
tier = "Free" | |
size = "F1" | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
subscription_id = "<--paste-your-subscription-id-here-->" | |
client_id = "<--paste-your-client-id-here-->" | |
tenant_id = "<--paste-your-tenant-id-here-->" | |
client_secret = "<--paste-your-secret-here-->" | |
environment = "dev01" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
variable "subscription_id" {} | |
variable "client_id" {} | |
variable "client_secret" {} | |
variable "tenant_id" {} | |
variable "environment" {} | |
# Configure the Azure Provider | |
provider "azurerm" { | |
subscription_id = "${var.subscription_id}" | |
client_id = "${var.client_id}" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<link href="https://cdn.botframework.com/botframework-webchat/latest/botchat.css" rel="stylesheet" /> | |
</head> | |
<body> | |
<div id="bot" /> | |
<script src="https://cdn.botframework.com/botframework-webchat/latest/botchat.js"></script> | |
<script> | |
BotChat.App({ |