Web App Args
data class WebAppArgs(val clientAffinityEnabled: Output<Boolean>? = null, val clientCertEnabled: Output<Boolean>? = null, val clientCertExclusionPaths: Output<String>? = null, val clientCertMode: Output<ClientCertMode>? = null, val cloningInfo: Output<CloningInfoArgs>? = null, val containerSize: Output<Int>? = null, val customDomainVerificationId: Output<String>? = null, val dailyMemoryTimeQuota: Output<Int>? = null, val enabled: Output<Boolean>? = null, val extendedLocation: Output<ExtendedLocationArgs>? = null, val hostNameSslStates: Output<List<HostNameSslStateArgs>>? = null, val hostNamesDisabled: Output<Boolean>? = null, val hostingEnvironmentProfile: Output<HostingEnvironmentProfileArgs>? = null, val httpsOnly: Output<Boolean>? = null, val hyperV: Output<Boolean>? = null, val identity: Output<ManagedServiceIdentityArgs>? = null, val isXenon: Output<Boolean>? = null, val keyVaultReferenceIdentity: Output<String>? = null, val kind: Output<String>? = null, val location: Output<String>? = null, val managedEnvironmentId: Output<String>? = null, val name: Output<String>? = null, val publicNetworkAccess: Output<String>? = null, val redundancyMode: Output<RedundancyMode>? = null, val reserved: Output<Boolean>? = null, val resourceGroupName: Output<String>? = null, val scmSiteAlsoStopped: Output<Boolean>? = null, val serverFarmId: Output<String>? = null, val siteConfig: Output<SiteConfigArgs>? = null, val storageAccountRequired: Output<Boolean>? = null, val tags: Output<Map<String, String>>? = null, val virtualNetworkSubnetId: Output<String>? = null, val vnetContentShareEnabled: Output<Boolean>? = null, val vnetImagePullEnabled: Output<Boolean>? = null, val vnetRouteAllEnabled: Output<Boolean>? = null) : ConvertibleToJava<WebAppArgs>
A web app, a mobile app backend, or an API app. Azure REST API version: 2022-09-01. Prior API version in Azure Native 1.x: 2020-12-01. Other available API versions: 2016-08-01, 2018-11-01, 2020-10-01.
Example Usage
Clone web app
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var webApp = new AzureNative.Web.WebApp("webApp", new()
{
CloningInfo = new AzureNative.Web.Inputs.CloningInfoArgs
{
AppSettingsOverrides =
{
{ "Setting1", "NewValue1" },
{ "Setting3", "NewValue5" },
},
CloneCustomHostNames = true,
CloneSourceControl = true,
ConfigureLoadBalancing = false,
HostingEnvironment = "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/hostingenvironments/aseforsites",
Overwrite = false,
SourceWebAppId = "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/sites/srcsiteg478",
SourceWebAppLocation = "West Europe",
},
Kind = "app",
Location = "East US",
Name = "sitef6141",
ResourceGroupName = "testrg123",
});
});
Content copied to clipboard
package main
import (
"github.com/pulumi/pulumi-azure-native-sdk/web/v2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := web.NewWebApp(ctx, "webApp", &web.WebAppArgs{
CloningInfo: &web.CloningInfoArgs{
AppSettingsOverrides: pulumi.StringMap{
"Setting1": pulumi.String("NewValue1"),
"Setting3": pulumi.String("NewValue5"),
},
CloneCustomHostNames: pulumi.Bool(true),
CloneSourceControl: pulumi.Bool(true),
ConfigureLoadBalancing: pulumi.Bool(false),
HostingEnvironment: pulumi.String("/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/hostingenvironments/aseforsites"),
Overwrite: pulumi.Bool(false),
SourceWebAppId: pulumi.String("/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/sites/srcsiteg478"),
SourceWebAppLocation: pulumi.String("West Europe"),
},
Kind: pulumi.String("app"),
Location: pulumi.String("East US"),
Name: pulumi.String("sitef6141"),
ResourceGroupName: pulumi.String("testrg123"),
})
if err != nil {
return err
}
return nil
})
}
Content copied to clipboard
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.web.WebApp;
import com.pulumi.azurenative.web.WebAppArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var webApp = new WebApp("webApp", WebAppArgs.builder()
.cloningInfo(Map.ofEntries(
Map.entry("appSettingsOverrides", Map.ofEntries(
Map.entry("Setting1", "NewValue1"),
Map.entry("Setting3", "NewValue5")
)),
Map.entry("cloneCustomHostNames", true),
Map.entry("cloneSourceControl", true),
Map.entry("configureLoadBalancing", false),
Map.entry("hostingEnvironment", "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/hostingenvironments/aseforsites"),
Map.entry("overwrite", false),
Map.entry("sourceWebAppId", "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg456/providers/Microsoft.Web/sites/srcsiteg478"),
Map.entry("sourceWebAppLocation", "West Europe")
))
.kind("app")
.location("East US")
.name("sitef6141")
.resourceGroupName("testrg123")
.build());
}
}
Content copied to clipboard
Create or Update web app
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var webApp = new AzureNative.Web.WebApp("webApp", new()
{
Kind = "app",
Location = "East US",
Name = "sitef6141",
ResourceGroupName = "testrg123",
ServerFarmId = "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp",
});
});
Content copied to clipboard
package main
import (
"github.com/pulumi/pulumi-azure-native-sdk/web/v2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := web.NewWebApp(ctx, "webApp", &web.WebAppArgs{
Kind: pulumi.String("app"),
Location: pulumi.String("East US"),
Name: pulumi.String("sitef6141"),
ResourceGroupName: pulumi.String("testrg123"),
ServerFarmId: pulumi.String("/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp"),
})
if err != nil {
return err
}
return nil
})
}
Content copied to clipboard
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.web.WebApp;
import com.pulumi.azurenative.web.WebAppArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var webApp = new WebApp("webApp", WebAppArgs.builder()
.kind("app")
.location("East US")
.name("sitef6141")
.resourceGroupName("testrg123")
.serverFarmId("/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/serverfarms/DefaultAsp")
.build());
}
}
Content copied to clipboard
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:web:WebApp sitef6141 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}
Content copied to clipboard
Constructors
Link copied to clipboard
fun WebAppArgs(clientAffinityEnabled: Output<Boolean>? = null, clientCertEnabled: Output<Boolean>? = null, clientCertExclusionPaths: Output<String>? = null, clientCertMode: Output<ClientCertMode>? = null, cloningInfo: Output<CloningInfoArgs>? = null, containerSize: Output<Int>? = null, customDomainVerificationId: Output<String>? = null, dailyMemoryTimeQuota: Output<Int>? = null, enabled: Output<Boolean>? = null, extendedLocation: Output<ExtendedLocationArgs>? = null, hostNameSslStates: Output<List<HostNameSslStateArgs>>? = null, hostNamesDisabled: Output<Boolean>? = null, hostingEnvironmentProfile: Output<HostingEnvironmentProfileArgs>? = null, httpsOnly: Output<Boolean>? = null, hyperV: Output<Boolean>? = null, identity: Output<ManagedServiceIdentityArgs>? = null, isXenon: Output<Boolean>? = null, keyVaultReferenceIdentity: Output<String>? = null, kind: Output<String>? = null, location: Output<String>? = null, managedEnvironmentId: Output<String>? = null, name: Output<String>? = null, publicNetworkAccess: Output<String>? = null, redundancyMode: Output<RedundancyMode>? = null, reserved: Output<Boolean>? = null, resourceGroupName: Output<String>? = null, scmSiteAlsoStopped: Output<Boolean>? = null, serverFarmId: Output<String>? = null, siteConfig: Output<SiteConfigArgs>? = null, storageAccountRequired: Output<Boolean>? = null, tags: Output<Map<String, String>>? = null, virtualNetworkSubnetId: Output<String>? = null, vnetContentShareEnabled: Output<Boolean>? = null, vnetImagePullEnabled: Output<Boolean>? = null, vnetRouteAllEnabled: Output<Boolean>? = null)
Functions
Properties
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard