Exemplo n.º 1
0
 public async ValueTask <IWebApp> CreateWebAppAsync(
     string webAppName,
     string databaseConnectionString,
     IAppServicePlan plan,
     IResourceGroup resourceGroup)
 {
     return(await this.azure.AppServices.WebApps
            .Define(webAppName)
            .WithExistingWindowsPlan(plan)
            .WithExistingResourceGroup(resourceGroup)
            .WithNetFrameworkVersion(NetFrameworkVersion.Parse("v6.0"))
            .WithConnectionString(
                name: "DefaultConnect",
                value: databaseConnectionString,
                type: ConnectionStringType.SQLAzure)
            .CreateAsync());
 }