Skip to content

Commit

Permalink
chore:Merge main to Telephony to remove new conflicts (#1224)
Browse files Browse the repository at this point in the history
* docs: Udpated extending-with-code doc (#1073)

* Updated extending with code doc

* Minor changes to extending with code

* More minor tweaks to extending with code

* Fixed most markdown warnings in extending with code

* Added comments to the code for extending with code doc

* fix: .NET Functions .csproj template fixes (#1065)

* Updating .NET Functions .csproj template to include all *.json files (except in www directory) as content; local.settings.json continues to not be included in publish output; fix www item include to use POSIX-style path separators; add _FunctionsSkipCleanOutput to PropertyGroup.

* Updating .NET Functions default content includes and excludes.

* fix: Fixing closing tag for local.settings.json Content element in .NET Functions .csproj template (#1075)

* Updating .NET Functions .csproj template to include all *.json files (except in www directory) as content; local.settings.json continues to not be included in publish output; fix www item include to use POSIX-style path separators; add _FunctionsSkipCleanOutput to PropertyGroup.

* Updating .NET Functions default content includes and excludes.

* Fixing closing tag for local.settings.json Content element in .NET Functions .csproj template.

* fix: Install .NET Core SDK for '.NET: Version, Sign & Pack' CI/CD pipeline stage (#1078)

* Removing reference to non-existant .editorconfig file from Microsoft.Bot.Components.sln; updating CI/CD pipeline to install .NET Core SDK for job 'job_pack_dotnet' to prevent defaulting to .NET 5.

* Adding 'steps:' back to dotnet-build-test-steps.yml.

* docs: R13 fit and finish for template README.md files (#1079)

* R13 fit and finish for template README.md files

- update template readme’s to contain final R13 copy
- update template generated readme’s to use final R13 template names
- update main repo readme to final R13 copy

* docs: R13 fit and finish for template README.md files

update template readme’s to contain final R13 copy
update template generated readme’s to use final R13 template names
update main repo readme to final R13 copy

Close microsoft/BotFramework-Composer#7573

Purpose

update template readme's with final R13 copy

* clean up disambiguation test

* Convert switch case condition to stringexpression, per schema definition (#1092)

* chore: bump js sdk version to 4.13.2-preview (#1096)

* convert svg icons to PNG to fix broken images in Teams (#1100)

* Corrected Skills Trigger to use correct route (#1102)

* fix: skill interrupting itself (#1107)

* fix skill interrupting itself

* lg fix

* clean up active skill property

* Update sln to point to correct path for package (#1093)

Co-authored-by: Thomas Chung <[email protected]>

* fix: Update .NET Functions to use wwwroot dir for static files (#1113)

* Update static files root directory for .NET Functions to wwwroot; bump JS SDK version to 4.13.3-preview.

* Removing ~ from JS SDK version since it does not apply to prerelease versions.

* add rewrite rule for manifest files for js webapps (#1116)

* bump: js to 4.13.4 (#1120)

* fix: Updated SDK dependencies (#1119)

* Updated SDK dependencies

* Temp fix for missing Adaptive.Test 4.13.2-preview

* Left dotnet packages at 4.13.1, resolved some test dependencies

* Did update dotnet package dependencies to 4.13.2

* chore: Add tags to Teams component project file (#1115)

* Add tags to Teams component project file

* Add config information to readme for Teams component

* fix: orphaned schemas (#1068)

Fixes #1067

* PR labeler corrections (#1125)

* cleanup (#1127)

* feat: generator-bot-adaptive: Added command line option to specify SDK version (#1137)

* generator-bot-adaptive: Added command line option to specify SDK version

* generator-bot-adaptive: Refactored platform values to objects.  No longer default sdkVersion option.

* generator-bot-adaptive: corrected lint errors

* chore: Update issue templates to reflect Components repository (#1141)

* Rename and update bug report

* Remove docs bug report (covered in bug report)

* remove calendar v2 bug

* Update pbx feature spec

* Remove question issue and add to config yml

* Update feature request and add other template for empty issues

* Formatting changes after testing on private repo

* Clean up pr template

* chore: Added FunctionalTests to repo (#1144)

* Added FunctionalTests to repo

* Adjusted some test file paths

* Removed functional to clean up git settings

* Readded functional without git dirs

* Restricted dotnet-build-test-steps to /tests/unit

* generator-bot-adaptive: Include *.model (#1140)

* generator-bot-adaptive: Updated default speak voice (#1147)

* chore: Update package metadata (#1148)

* Updating package metadata for generators and components to reflect 1.0.0 GA.

* Updating component package versions to GA release versions.

* Update yarn.lock.

* feat: Azure resource deployment for Components Functional Tests pipelines (Empty Bot placeholders)  (#1149)

* Update createSharedResources.yml

Rename bffn instances to bfcfn to avoid overlap

* Move /tests/functional/build/templates to /build/templates

* Set up CI with Azure Pipelines

[skip ci]

* Remove DotnetComposer, JS, Python bots

* Remove all DotNet bots except for Simple Host Bot

* Remove additional other language references and rename variables to bfcfn

* Replace bffn with bfcfn

* Update directory of SimpleHostBot

* Rename bot vars to empty bot

* rename additional refs

* remove duplicate app in variables

* add functions to dotnet

* add JS parameters and template for empty bot in webapp/functions

* add prepare_jsgroup step

* fix location to js simple host bot

* Remove python refs

* Add InternalAppSerivcePlanJSName var

* Remove additional Python steps in shared resource creation, bot resource deployment and cleanup

* Change default value of appinsights resource

* Add blog storage deployment to shared resource creation

* add parameter to cli call to deploy storage

* fix casing

* chore: @microsoft/generator-bot-adaptive happy path unit tests (#1091)

* Adding Mocha unit test support to generator-bot-adaptive; implemented simple test for .NET Web App generation, as well as empty stubs for other variations.

* Further progress on .NET Web App generator unit tests for generator-bot-adaptive.

* Implementing basic happy path unit tests for generator-bot-adaptive for all permutations of platform and integration.

* Addressing majority of eslint errors except for escape char errors in dotnet-webapp.test.js and dotnet-functions.test.js; addressing in next commit.

* Fixing remaining eslint issues around regular expressions in dotnet-webapp.test.js and dotnet-functions.test.js.

* Renaming tests dir to test.

* Addressing PR feedback from Josh.

* Fixing references to platform in child generators to correctly use name property.

* chore: Wire up yeoman unit tests in CI/CD pipelines (#1152)

* Adding npm test step to CI/CD pipeline templates.

* Add comment to generator-bot-adaptive to trigger pipeline.

* Restoring dependencies in npm-test-steps.yml.

* Updating npm-test-steps.yml to simply run 'yarn run test' due to difference in yarn package restoration location.

* Updating npm-test-steps.yml to manually check for presence of test script in package.json, and conditionally only run 'yarn run test' if a test script is defined.

* Removing comment from generator-bot-adaptive; update step name for determining if test script is present.

* feat: functional tests generate empty bots in dotnet (#1156)

* fix: GetManager issue with name entity not set (#1163)

* Add Teams package unit tests (#1171)

* fix: Stevenic/ac fix (#1164)

* Fixed typo in schema for UpdateActivity

* Forgot to copy activityId to outgoing activity in UpdateAdaptiveCard

* feat: functional tests generate empty bots in js (#1186)

* Add generator/deploy steps to js deploy steps and update parameters

* Add dir workspace step to js

* Replace working directory instances with solution directory var

* Remove skillv3 refs from deploy steps

* Add step to remove web.config from generated bot

* only remove web.config for js webapp

* Rename /bots directory to /workspace

* fix comment

* fix: R14 template issues (#1188)

* update generators if/else conditions to include =

* update ifConditions in dev projects

* remove extraneous schema files and properties

* Fix bot tour buttons in Teams

* chore: clarify yarn usage in pipelines & package with version name to aid deployment (#1202)

* rename npm references to yarn and consolidate debug workspace steps

* Rename addl npm to yarn refs

* Add $(NpmPackageVersion) to yarn pack filename

* add tgz suffix to yarn pack step

* get name for yarn pack

* remove invalid filename characters

* Write package name and file name to output

* clean up comments

* Fixed broken links that open url in Composer modal (#1204)

* build: Add Components functional test scenarios to daily pipelines (#1210)

* Update runTestScenarios.yml with Components environment

* enable only components bots

* provide components env to consinfugerConsumers

* remove skill refs from configure consumers and add components bots to test app settings

* switch to new location of csproj

* add components bots to echo tests

* Remove unused skills tests

* Remove skill bot refs from simple test

* Revert "Remove skill bot refs from simple test"

This reverts commit 9a545b7.

* Add EmptyBot json/transcript, remove functions bots, consolidate nuget refs

* rename singleturn to emptybot

* rename singleturn to empty bot and remove functions bots in pipelines

* remove skillbots from functional tests

* remove assertion of locale

* clean up speak properties to what is generated from generator

* Rename to ComponentsFunctionalTests

* rename addl skillfunctionaltests refs to components

* add readme to transcript conveter

* Update README.md

* chore: Merge 4.14 To Main (#1201)

* Bumping DotNet version

* Update js sdk to 4.14rc0 as well

* update tests

* Update JS tests

* Update JS test expectation

* chore: Cherry pick 1171 and 1164 into 4.14 (#1172)

* Add Teams package unit tests (#1171)

* fix: Stevenic/ac fix (#1164)

* Fixed typo in schema for UpdateActivity

* Forgot to copy activityId to outgoing activity in UpdateAdaptiveCard

Co-authored-by: Ryan Lengel Isgrig <[email protected]>
Co-authored-by: Steven Ickman <[email protected]>

* feat: Update bot framework package deps (#1168)

* Update package.json on adaptive + empty

* Update more package depdendency

* Update template package.jsons

* Update yarn.lock

* Update old school csharp skills

* Update Teams, AdaptiveCards package and misc projs

* Update SendMessageToTeamsChannelAsync to work with CloudAdapter (#1170)

* chore: Cherry pick 1171 and 1164 into 4.14 (#1172)

* Add Teams package unit tests (#1171)

* fix: Stevenic/ac fix (#1164)

* Fixed typo in schema for UpdateActivity

* Forgot to copy activityId to outgoing activity in UpdateAdaptiveCard

Co-authored-by: Ryan Lengel Isgrig <[email protected]>
Co-authored-by: Steven Ickman <[email protected]>

Co-authored-by: Thomas Chung <[email protected]>
Co-authored-by: Eric Dahlvang <[email protected]>
Co-authored-by: Ryan Lengel Isgrig <[email protected]>
Co-authored-by: Steven Ickman <[email protected]>

> Looks good. Let's document all of the processes to upgrade versions for all types of components in the repo so that others can do the same.
> i.e.
> Generators
> 
> 1. generator-bot-adaptive/package.json - bump version
> 2. generator-bot-_/packagejson (the rest) - bump version and dependencies:@microsoft/generator-bot-_ versions
> 
> Csproj packages
> 
> 1. Bump version of Microsoft.Bot.Builder.* dependencies
> 
> Nuspec packages
> 
> 1. Bump version of Mocrosoft.Bot.Builder.* dependencies
>    Npm packages
> 2. Bump versions of botbuilder dependencies

Good idea. As we figure this out we should just write down the steps.

* fix: Send message to teams channel support both adapters (#1174)

* Enable SendMessageToTeamsChannel with either BotFrameworkAdapter or CloudAdapter

* Get appId from claims

* Throw if adapter is not a known type to support SendMessageToTeamsChannel

* feat: Update package versions (#1182)

* Update graph package version

* Update graph

* Update Teams package

* Update teams JS package

* Update adaptive cards

* HelpAndCancel

* Update helpandcancel + welcome dependencies

* Change to minor version update

* Update to correct JS preview platform.js

* Update generator package version (#1183)

* Update .NET SDK to 4.14 final (#1187)

* Allow previews to generate version as well (#1189)

Co-authored-by: Thomas Chung <[email protected]>

* fix: nuget package version override to allow "preview" ring (#1191)

* Fix nuget versioning steps

* Fix Teams test reference

* Fix Microsoft.Bot.Builder.Dialogs.Adaptive.Testing

Co-authored-by: Thomas Chung <[email protected]>

* feat: Use preview version for RC/preview releases (#1194)

* initial changes

* Update templates to use preview

Co-authored-by: Thomas Chung <[email protected]>

* chore: fix netcore install steps for various deployment stages (#1196)

* pull netcore install steps to build-test and package separately

* remove netcore step from signing as it is used in packaging

* feat: Update everything with JS to GA (#1195)

* Update everything to GA

* Update yarn lock

* Update yarn lock

* Update dependency package version

* Add missing dependency

Co-authored-by: Thomas Chung <[email protected]>

* chore: update deprecated nuget package licenseurl properties (#1197)

* Update directory.build.props LicenseUrl tags with PackageLicenseExpression referencing the MIT license

* replace nuspec licenseURl with license

* replace nuspec license with license type referencing MIT

* Update Directory.Build.props

Add NU5048 to NoWarn

* Update Directory.Build.props

* Update dummy test script in node packages with clearer message and to not "exit 1" (#1199)

* port: GetMeetingInfo, meeting start/end events [JS] (#1175)

* port: JS Teams Tests and CloudAdapter support (#1200)

* port: GetMeetingInfo, meeting start/end events [.NET] (#1178)

* chore: Moving branch to RC0 + bump C# SDK to 4.14.1 (#1205)

* chore: build workspace prior to testing (#1206)

* Empty out sdk schema and uischema to force regen (#1208)

Co-authored-by: Thomas Chung <[email protected]>

* fix: typo in OnMEBotMessagePreviewSend (#1212)

* Update packages and tempalte reference to 1.1.0 GA (#1213)

* fix: fully remove unnecessary onTeamsMEConfigurationSetting (#1215)

* Bump version to 1.1.1 and correct references (#1216)

Co-authored-by: Thomas Chung <[email protected]>
Co-authored-by: Ryan Lengel Isgrig <[email protected]>
Co-authored-by: Steven Ickman <[email protected]>
Co-authored-by: Eric Dahlvang <[email protected]>
Co-authored-by: Michael Richardson <[email protected]>

* build: add functions app deployment/testing to functional tests (#1218)

* Add stub for functions ARM resource

* Import functions ARM tempalte from composer and test deploying to it

* add shared service farm to function app

* add fnctions steps to js deploy

* revert shared serverfarm and fix js build directory

* separate dotnet/js function arm deployment templates

* Add functions bots to test scenarios

* Fix ref for DotNetFunctions consumer

Co-authored-by: tracyboehrer <[email protected]>
Co-authored-by: Peter Innes <[email protected]>
Co-authored-by: Scott Gellock <[email protected]>
Co-authored-by: Ryan Lengel Isgrig <[email protected]>
Co-authored-by: Josh Gummersall <[email protected]>
Co-authored-by: lauren-mills <[email protected]>
Co-authored-by: Thomas Chung <[email protected]>
Co-authored-by: Thomas Chung <[email protected]>
Co-authored-by: Ben Brown <[email protected]>
Co-authored-by: Eric Dahlvang <[email protected]>
Co-authored-by: Andrew Clear <[email protected]>
Co-authored-by: Steven Ickman <[email protected]>
Co-authored-by: Michael Richardson <[email protected]>
Co-authored-by: Pooja Nagpal <[email protected]>
  • Loading branch information
15 people authored Jul 19, 2021
1 parent 01d0bfe commit b30f43d
Show file tree
Hide file tree
Showing 10 changed files with 376 additions and 48 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -388,6 +388,9 @@ experimental/generator-dotnet-yeoman/node_modules
# Allow the packages directory under tests
!/tests/unit/[Pp]ackages/*

# Allow the packages directory under tests
!/tests/unit/[Pp]ackages/*

# Ignore correct yarn files (no zero install support)
.yarn/*
!.yarn/patches
Expand Down
115 changes: 115 additions & 0 deletions build/templates/template-function-dotnet-bot-resources.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,115 @@
{
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"appId": {
"type": "string",
"metadata": {
"description": "Active Directory App ID, set as MicrosoftAppId in the Web App's Application Settings."
}
},
"appSecret": {
"type": "string",
"metadata": {
"description": "Active Directory App Password, set as MicrosoftAppPassword in the Web App's Application Settings."
}
},
"botName": {
"type": "string"
},
"botLocation": {
"type": "string"
},
"appInsightsName": {
"type": "string",
"defaultValue": ""
},
"appServicePlanName": {
"type": "string"
},
"appServicePlanResourceGroup": {
"type": "string"
},
"botSku": {
"type": "string",
"defaultValue": "F0",
"metadata": {
"description": "The pricing tier of the Bot Service Registration. Acceptable values are F0 and S1."
}
}
},
"variables": {
"siteHost": "[concat(parameters('botName'), '.azurewebsites.net')]",
"botEndpoint": "[concat('https://', variables('siteHost'), '/api/messages')]",
"publishingUsername": "[concat('$', parameters('botName'))]"
},
"resources": [
{
"type": "Microsoft.Web/sites",
"apiVersion": "2015-08-01",
"location": "[parameters('botLocation')]",
"kind": "functionapp",
"name": "[parameters('botName')]",
"properties": {
"name": "[parameters('botName')]",
"kind": "functionapp",
"httpsOnly": true,
"alwaysOn": true,
"webSocketsEnabled": true
},
"resources": [
{
"name": "appsettings",
"type": "config",
"apiVersion": "2015-08-01",
"dependsOn": [
"[concat('Microsoft.Web/Sites/', parameters('botName'))]"
],
"properties": {
"FUNCTIONS_EXTENSION_VERSION": "~3",
"FUNCTIONS_WORKER_RUNTIME": "dotnet",
"APPINSIGHTS_INSTRUMENTATIONKEY": "[if(empty(parameters('appInsightsName')), '', reference(resourceId(parameters('appServicePlanResourceGroup'),'Microsoft.Insights/components', parameters('appInsightsName')), '2015-05-01', 'Full').properties.InstrumentationKey)]",
"MicrosoftAppId": "[parameters('appId')]",
"MicrosoftAppPassword": "[parameters('appSecret')]"
}
}
]
},
{
"type": "Microsoft.Web/sites/hostNameBindings",
"apiVersion": "2020-09-01",
"name": "[concat(parameters('botName'), '/', parameters('botName'), '.azurewebsites.net')]",
"location": "[parameters('botLocation')]",
"dependsOn": [
"[resourceId('Microsoft.Web/sites', parameters('botName'))]"
],
"properties": {
"siteName": "[parameters('botName')]",
"hostNameType": "Verified"
}
},
{
"type": "Microsoft.BotService/botServices",
"apiVersion": "2020-06-02",
"name": "[parameters('botName')]",
"location": "global",
"kind": "bot",
"sku": {
"name": "[parameters('botSku')]"
},
"dependsOn": [
"[resourceId('Microsoft.Web/sites', parameters('botName'))]"
],
"properties": {
"name": "[parameters('botName')]",
"displayName": "[parameters('botName')]",
"endpoint": "[variables('botEndpoint')]",
"msaAppId": "[parameters('appId')]",
"developerAppInsightsApplicationId": "",
"developerAppInsightKey": "",
"publishingCredentials": null,
"storageResourceId": null
}
}
]
}
116 changes: 116 additions & 0 deletions build/templates/template-function-js-bot-resources.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
{
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"appId": {
"type": "string",
"metadata": {
"description": "Active Directory App ID, set as MicrosoftAppId in the Web App's Application Settings."
}
},
"appSecret": {
"type": "string",
"metadata": {
"description": "Active Directory App Password, set as MicrosoftAppPassword in the Web App's Application Settings."
}
},
"botName": {
"type": "string"
},
"botLocation": {
"type": "string"
},
"appInsightsName": {
"type": "string",
"defaultValue": ""
},
"appServicePlanName": {
"type": "string"
},
"appServicePlanResourceGroup": {
"type": "string"
},
"botSku": {
"type": "string",
"defaultValue": "F0",
"metadata": {
"description": "The pricing tier of the Bot Service Registration. Acceptable values are F0 and S1."
}
}
},
"variables": {
"siteHost": "[concat(parameters('botName'), '.azurewebsites.net')]",
"botEndpoint": "[concat('https://', variables('siteHost'), '/api/messages')]",
"publishingUsername": "[concat('$', parameters('botName'))]"
},
"resources": [
{
"type": "Microsoft.Web/sites",
"apiVersion": "2015-08-01",
"location": "[parameters('botLocation')]",
"kind": "functionapp",
"name": "[parameters('botName')]",
"properties": {
"name": "[parameters('botName')]",
"kind": "functionapp",
"httpsOnly": true,
"alwaysOn": true,
"webSocketsEnabled": true
},
"resources": [
{
"name": "appsettings",
"type": "config",
"apiVersion": "2015-08-01",
"dependsOn": [
"[concat('Microsoft.Web/Sites/', parameters('botName'))]"
],
"properties": {
"FUNCTIONS_EXTENSION_VERSION": "~3",
"FUNCTIONS_WORKER_RUNTIME": "node",
"WEBSITE_NODE_DEFAULT_VERSION": "~14",
"APPINSIGHTS_INSTRUMENTATIONKEY": "[if(empty(parameters('appInsightsName')), '', reference(resourceId(parameters('appServicePlanResourceGroup'),'Microsoft.Insights/components', parameters('appInsightsName')), '2015-05-01', 'Full').properties.InstrumentationKey)]",
"MicrosoftAppId": "[parameters('appId')]",
"MicrosoftAppPassword": "[parameters('appSecret')]"
}
}
]
},
{
"type": "Microsoft.Web/sites/hostNameBindings",
"apiVersion": "2020-09-01",
"name": "[concat(parameters('botName'), '/', parameters('botName'), '.azurewebsites.net')]",
"location": "[parameters('botLocation')]",
"dependsOn": [
"[resourceId('Microsoft.Web/sites', parameters('botName'))]"
],
"properties": {
"siteName": "[parameters('botName')]",
"hostNameType": "Verified"
}
},
{
"type": "Microsoft.BotService/botServices",
"apiVersion": "2020-06-02",
"name": "[parameters('botName')]",
"location": "global",
"kind": "bot",
"sku": {
"name": "[parameters('botSku')]"
},
"dependsOn": [
"[resourceId('Microsoft.Web/sites', parameters('botName'))]"
],
"properties": {
"name": "[parameters('botName')]",
"displayName": "[parameters('botName')]",
"endpoint": "[variables('botEndpoint')]",
"msaAppId": "[parameters('appId')]",
"developerAppInsightsApplicationId": "",
"developerAppInsightKey": "",
"publishingCredentials": null,
"storageResourceId": null
}
}
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,19 @@ public enum HostBot
/// </summary>
EmptyBotDotNetWebApp,

/// <summary>
/// Empty bot implemented using DotNet and Functions.
/// </summary>
EmptyBotDotNetFunctions,

/// <summary>
/// Empty bot implemented using JS and Web App.
/// </summary>
EmptyBotJSWebApp
EmptyBotJSWebApp,

/// <summary>
/// Empty bot implemented using JS and Functions.
/// </summary>
EmptyBotJSFunctions
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@ public static IEnumerable<object[]> TestCases()
var hostBots = new List<HostBot>
{
HostBot.EmptyBotDotNetWebApp,
HostBot.EmptyBotJSWebApp
HostBot.EmptyBotDotNetFunctions,
HostBot.EmptyBotJSWebApp,
HostBot.EmptyBotJSFunctions
};

var scripts = new List<string> { "EmptyBot.json" };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,17 @@
"BotId": "bfcfnemptybotdotnetwebapp",
"DirectLineSecret": ""
},
"EmptyBotDotNetFunctions": {
"BotId": "bfcfnemptybotdotnetfunctions",
"DirectLineSecret": ""
},
"EmptyBotJSWebApp": {
"BotId": "bfcfnemptybotjswebapp",
"DirectLineSecret": ""
},
"EmptyBotJSFunctions": {
"BotId": "bfcfnemptybotjsfunctions",
"DirectLineSecret": ""
}
}
}
71 changes: 49 additions & 22 deletions tests/functional/build/yaml/deployBotResources/dotnet/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -154,30 +154,57 @@ stages:
pathToPublish: "$(SYSTEM.DEFAULTWORKINGDIRECTORY)/${{ parameters.buildFolder }}/${{ bot.name }}/${{ bot.name }}.zip"
artifactName: dotnet-$(BUILD.BUILDID)

- ${{ if eq(bot.project.integration, 'webapp') }}:
# Create App Service and Bot Channel Registration
- template: ../common/createAppService.yml
parameters:
appId: $(APPID)
appInsight: "${{ parameters.appInsight }}"
appSecret: $(APPSECRET)
appServicePlan: "${{ parameters.appServicePlan }}"
appServicePlanRG: "${{ parameters.appServicePlanRG }}"
azureSubscription: "${{ parameters.azureSubscription }}"
botGroup: "${{ parameters.resourceGroup }}"
botName: "${{ bot.name }}"
botPricingTier: "${{ parameters.botPricingTier }}"
resourceSuffix: "${{ parameters.resourceSuffix }}"
templateFile: "build/templates/template-bot-resources.json"
- template: ../common/createAppService.yml
parameters:
appId: $(APPID)
appInsight: "${{ parameters.appInsight }}"
appSecret: $(APPSECRET)
appServicePlan: "${{ parameters.appServicePlan }}"
appServicePlanRG: "${{ parameters.appServicePlanRG }}"
azureSubscription: "${{ parameters.azureSubscription }}"
botGroup: "${{ parameters.resourceGroup }}"
botName: "${{ bot.name }}"
botPricingTier: "${{ parameters.botPricingTier }}"
resourceSuffix: "${{ parameters.resourceSuffix }}"
templateFile: "build/templates/template-bot-resources.json"

# Deploy bot
- task: AzureWebApp@1
displayName: 'Deploy Azure Web App : ${{ bot.name }}-$(BUILD.BUILDID)'
inputs:
azureSubscription: "${{ parameters.azureSubscription }}"
appName: '${{ bot.name }}${{ parameters.resourceSuffix }}-$(BUILD.BUILDID)'
resourceGroupName: '${{ parameters.resourceGroup }}'
package: '$(SYSTEM.DEFAULTWORKINGDIRECTORY)/${{ parameters.buildFolder }}/${{ bot.name }}/${{ bot.name }}.zip'
deploymentMethod: runFromPackage
# Deploy bot to Azure Web App
- task: AzureWebApp@1
displayName: 'Deploy Azure Web App : ${{ bot.name }}-$(BUILD.BUILDID)'
inputs:
azureSubscription: "${{ parameters.azureSubscription }}"
appName: '${{ bot.name }}${{ parameters.resourceSuffix }}-$(BUILD.BUILDID)'
resourceGroupName: '${{ parameters.resourceGroup }}'
package: '$(SYSTEM.DEFAULTWORKINGDIRECTORY)/${{ parameters.buildFolder }}/${{ bot.name }}/${{ bot.name }}.zip'
deploymentMethod: runFromPackage

- ${{ if eq(bot.project.integration, 'functions') }}:
# Create Functions App and Bot Channel Registration
- template: ../common/createAppService.yml
parameters:
appId: $(APPID)
appInsight: "${{ parameters.appInsight }}"
appSecret: $(APPSECRET)
appServicePlan: "${{ parameters.appServicePlan }}"
appServicePlanRG: "${{ parameters.appServicePlanRG }}"
azureSubscription: "${{ parameters.azureSubscription }}"
botGroup: "${{ parameters.resourceGroup }}"
botName: "${{ bot.name }}"
botPricingTier: "${{ parameters.botPricingTier }}"
resourceSuffix: "${{ parameters.resourceSuffix }}"
templateFile: "build/templates/template-function-dotnet-bot-resources.json"

# Deploy bot to Azure Functions
- task: AzureFunctionApp@1
displayName: 'Deploy Functions App : ${{ bot.name }}-$(BUILD.BUILDID)'
inputs:
azureSubscription: "${{ parameters.azureSubscription }}"
appType: 'functionApp'
appName: '${{ bot.name }}${{ parameters.resourceSuffix }}-$(BUILD.BUILDID)'
package: '$(SYSTEM.DEFAULTWORKINGDIRECTORY)/${{ parameters.buildFolder }}/${{ bot.name }}/${{ bot.name }}.zip'
deploymentMethod: runFromPackage

# Configure OAuth
- ${{ if eq(bot.type, 'Skill') }}:
Expand Down
Loading

0 comments on commit b30f43d

Please sign in to comment.