import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * Manages a Windows Web App Slot. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as azure from "@pulumi/azure"; * * const example = new azure.core.ResourceGroup("example", { * name: "example-resources", * location: "West Europe", * }); * const exampleServicePlan = new azure.appservice.ServicePlan("example", { * name: "example-plan", * resourceGroupName: example.name, * location: example.location, * osType: "Windows", * skuName: "P1v2", * }); * const exampleWindowsWebApp = new azure.appservice.WindowsWebApp("example", { * name: "example-windows-web-app", * resourceGroupName: example.name, * location: exampleServicePlan.location, * servicePlanId: exampleServicePlan.id, * siteConfig: {}, * }); * const exampleWindowsWebAppSlot = new azure.appservice.WindowsWebAppSlot("example", { * name: "example-slot", * appServiceId: exampleWindowsWebApp.id, * siteConfig: {}, * }); * ``` * * ## API Providers * * * This resource uses the following Azure API Providers: * * * `Microsoft.Web` - 2023-12-01 * * ## Import * * Windows Web Apps can be imported using the `resource id`, e.g. * * ```sh * $ pulumi import azure:appservice/windowsWebAppSlot:WindowsWebAppSlot example /subscriptions/12345678-1234-9876-4563-123456789012/resourceGroups/resGroup1/providers/Microsoft.Web/sites/site1/slots/slot1 * ``` */ export declare class WindowsWebAppSlot extends pulumi.CustomResource { /** * Get an existing WindowsWebAppSlot resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input, state?: WindowsWebAppSlotState, opts?: pulumi.CustomResourceOptions): WindowsWebAppSlot; /** * Returns true if the given object is an instance of WindowsWebAppSlot. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is WindowsWebAppSlot; /** * The ID of the Windows Web App this Deployment Slot will be part of. Changing this forces a new Windows Web App to be created. */ readonly appServiceId: pulumi.Output; /** * A map of key-value pairs of App Settings. */ readonly appSettings: pulumi.Output<{ [key: string]: string; } | undefined>; /** * An `authSettings` block as defined below. */ readonly authSettings: pulumi.Output; /** * An `authSettingsV2` block as defined below. */ readonly authSettingsV2: pulumi.Output; /** * A `backup` block as defined below. */ readonly backup: pulumi.Output; /** * Should Client Affinity be enabled? */ readonly clientAffinityEnabled: pulumi.Output; /** * Should Client Certificates be enabled? */ readonly clientCertificateEnabled: pulumi.Output; /** * Paths to exclude when using client certificates, separated by ; */ readonly clientCertificateExclusionPaths: pulumi.Output; /** * The Client Certificate mode. Possible values are `Required`, `Optional`, and `OptionalInteractiveUser`. This property has no effect when `clientCertificateEnabled` is `false`. Defaults to `Required`. */ readonly clientCertificateMode: pulumi.Output; /** * One or more `connectionString` blocks as defined below. */ readonly connectionStrings: pulumi.Output; /** * The identifier used by App Service to perform domain ownership verification via DNS TXT record. */ readonly customDomainVerificationId: pulumi.Output; /** * The default hostname of the Windows Web App Slot. */ readonly defaultHostname: pulumi.Output; /** * Should the Windows Web App Slot be enabled? Defaults to `true`. */ readonly enabled: pulumi.Output; /** * Should the default FTP Basic Authentication publishing profile be enabled. Defaults to `true`. */ readonly ftpPublishBasicAuthenticationEnabled: pulumi.Output; /** * The ID of the App Service Environment used by App Service Slot. */ readonly hostingEnvironmentId: pulumi.Output; /** * Should the Windows Web App Slot require HTTPS connections. Defaults to `false`. */ readonly httpsOnly: pulumi.Output; /** * An `identity` block as defined below. */ readonly identity: pulumi.Output; /** * The User Assigned Identity ID used for accessing KeyVault secrets. The identity must be assigned to the application in the `identity` block. [For more information see - Access vaults with a user-assigned identity](https://docs.microsoft.com/azure/app-service/app-service-key-vault-references#access-vaults-with-a-user-assigned-identity) */ readonly keyVaultReferenceIdentityId: pulumi.Output; /** * The Kind value for this Windows Web App Slot. */ readonly kind: pulumi.Output; /** * A `logs` block as defined below. */ readonly logs: pulumi.Output; /** * The name which should be used for this Windows Web App Slot. Changing this forces a new Windows Web App Slot to be created. * * > **Note:** Terraform will perform a name availability check as part of the creation progress, if this Web App is part of an App Service Environment terraform will require Read permission on the App Service Environment for this to complete reliably. */ readonly name: pulumi.Output; /** * A list of outbound IP addresses - such as `["52.23.25.3", "52.143.43.12"]` */ readonly outboundIpAddressLists: pulumi.Output; /** * A comma separated list of outbound IP addresses - such as `52.23.25.3,52.143.43.12`. */ readonly outboundIpAddresses: pulumi.Output; /** * A list of possible outbound ip address. */ readonly possibleOutboundIpAddressLists: pulumi.Output; /** * A comma separated list of outbound IP addresses - such as `52.23.25.3,52.143.43.12,52.143.43.17` - not all of which are necessarily in use. Superset of `outboundIpAddresses`. */ readonly possibleOutboundIpAddresses: pulumi.Output; /** * Should public network access be enabled for the Web App. Defaults to `true`. */ readonly publicNetworkAccessEnabled: pulumi.Output; /** * The ID of the Service Plan in which to run this slot. If not specified the same Service Plan as the Windows Web App will be used. * * > **Note:** `servicePlanId` should only be specified if it differs from the Service Plan of the associated Windows Web App. */ readonly servicePlanId: pulumi.Output; /** * A `siteConfig` block as defined below. */ readonly siteConfig: pulumi.Output; /** * A `siteCredential` block as defined below. */ readonly siteCredentials: pulumi.Output; /** * One or more `storageAccount` blocks as defined below. * * > **Note:** Using this value requires `WEBSITE_RUN_FROM_PACKAGE=1` to be set on the App in `appSettings`. Refer to the [Azure docs](https://docs.microsoft.com/en-us/azure/app-service/deploy-run-package) for further details. */ readonly storageAccounts: pulumi.Output; /** * A mapping of tags which should be assigned to the Windows Web App Slot. */ readonly tags: pulumi.Output<{ [key: string]: string; } | undefined>; /** * Whether backup and restore operations over the linked virtual network are enabled. Defaults to `false`. */ readonly virtualNetworkBackupRestoreEnabled: pulumi.Output; /** * Whether traffic for the image pull should be routed over the virtual network. * * > **Note:** `virtualNetworkImagePullEnabled` must be set to `true` when running in an App Service Environment. */ readonly virtualNetworkImagePullEnabled: pulumi.Output; /** * The subnet id which will be used by this Web App Slot for [regional virtual network integration](https://docs.microsoft.com/en-us/azure/app-service/overview-vnet-integration#regional-virtual-network-integration). * * > **Note:** The AzureRM Terraform provider provides regional virtual network integration via the standalone resource appServiceVirtualNetworkSwiftConnection and in-line within this resource using the `virtualNetworkSubnetId` property. You cannot use both methods simultaneously. If the virtual network is set via the resource `appServiceVirtualNetworkSwiftConnection` then `ignoreChanges` should be used in the web app slot configuration. * * > **Note:** Assigning the `virtualNetworkSubnetId` property requires [RBAC permissions on the subnet](https://docs.microsoft.com/en-us/azure/app-service/overview-vnet-integration#permissions) */ readonly virtualNetworkSubnetId: pulumi.Output; /** * Should the default WebDeploy Basic Authentication publishing credentials enabled. Defaults to `true`. * * > **Note:** Setting this value to true will disable the ability to use `zipDeployFile` which currently relies on the default publishing profile. */ readonly webdeployPublishBasicAuthenticationEnabled: pulumi.Output; /** * The local path and filename of the Zip packaged application to deploy to this Windows Web App. */ readonly zipDeployFile: pulumi.Output; /** * Create a WindowsWebAppSlot resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: WindowsWebAppSlotArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering WindowsWebAppSlot resources. */ export interface WindowsWebAppSlotState { /** * The ID of the Windows Web App this Deployment Slot will be part of. Changing this forces a new Windows Web App to be created. */ appServiceId?: pulumi.Input; /** * A map of key-value pairs of App Settings. */ appSettings?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * An `authSettings` block as defined below. */ authSettings?: pulumi.Input; /** * An `authSettingsV2` block as defined below. */ authSettingsV2?: pulumi.Input; /** * A `backup` block as defined below. */ backup?: pulumi.Input; /** * Should Client Affinity be enabled? */ clientAffinityEnabled?: pulumi.Input; /** * Should Client Certificates be enabled? */ clientCertificateEnabled?: pulumi.Input; /** * Paths to exclude when using client certificates, separated by ; */ clientCertificateExclusionPaths?: pulumi.Input; /** * The Client Certificate mode. Possible values are `Required`, `Optional`, and `OptionalInteractiveUser`. This property has no effect when `clientCertificateEnabled` is `false`. Defaults to `Required`. */ clientCertificateMode?: pulumi.Input; /** * One or more `connectionString` blocks as defined below. */ connectionStrings?: pulumi.Input[]>; /** * The identifier used by App Service to perform domain ownership verification via DNS TXT record. */ customDomainVerificationId?: pulumi.Input; /** * The default hostname of the Windows Web App Slot. */ defaultHostname?: pulumi.Input; /** * Should the Windows Web App Slot be enabled? Defaults to `true`. */ enabled?: pulumi.Input; /** * Should the default FTP Basic Authentication publishing profile be enabled. Defaults to `true`. */ ftpPublishBasicAuthenticationEnabled?: pulumi.Input; /** * The ID of the App Service Environment used by App Service Slot. */ hostingEnvironmentId?: pulumi.Input; /** * Should the Windows Web App Slot require HTTPS connections. Defaults to `false`. */ httpsOnly?: pulumi.Input; /** * An `identity` block as defined below. */ identity?: pulumi.Input; /** * The User Assigned Identity ID used for accessing KeyVault secrets. The identity must be assigned to the application in the `identity` block. [For more information see - Access vaults with a user-assigned identity](https://docs.microsoft.com/azure/app-service/app-service-key-vault-references#access-vaults-with-a-user-assigned-identity) */ keyVaultReferenceIdentityId?: pulumi.Input; /** * The Kind value for this Windows Web App Slot. */ kind?: pulumi.Input; /** * A `logs` block as defined below. */ logs?: pulumi.Input; /** * The name which should be used for this Windows Web App Slot. Changing this forces a new Windows Web App Slot to be created. * * > **Note:** Terraform will perform a name availability check as part of the creation progress, if this Web App is part of an App Service Environment terraform will require Read permission on the App Service Environment for this to complete reliably. */ name?: pulumi.Input; /** * A list of outbound IP addresses - such as `["52.23.25.3", "52.143.43.12"]` */ outboundIpAddressLists?: pulumi.Input[]>; /** * A comma separated list of outbound IP addresses - such as `52.23.25.3,52.143.43.12`. */ outboundIpAddresses?: pulumi.Input; /** * A list of possible outbound ip address. */ possibleOutboundIpAddressLists?: pulumi.Input[]>; /** * A comma separated list of outbound IP addresses - such as `52.23.25.3,52.143.43.12,52.143.43.17` - not all of which are necessarily in use. Superset of `outboundIpAddresses`. */ possibleOutboundIpAddresses?: pulumi.Input; /** * Should public network access be enabled for the Web App. Defaults to `true`. */ publicNetworkAccessEnabled?: pulumi.Input; /** * The ID of the Service Plan in which to run this slot. If not specified the same Service Plan as the Windows Web App will be used. * * > **Note:** `servicePlanId` should only be specified if it differs from the Service Plan of the associated Windows Web App. */ servicePlanId?: pulumi.Input; /** * A `siteConfig` block as defined below. */ siteConfig?: pulumi.Input; /** * A `siteCredential` block as defined below. */ siteCredentials?: pulumi.Input[]>; /** * One or more `storageAccount` blocks as defined below. * * > **Note:** Using this value requires `WEBSITE_RUN_FROM_PACKAGE=1` to be set on the App in `appSettings`. Refer to the [Azure docs](https://docs.microsoft.com/en-us/azure/app-service/deploy-run-package) for further details. */ storageAccounts?: pulumi.Input[]>; /** * A mapping of tags which should be assigned to the Windows Web App Slot. */ tags?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * Whether backup and restore operations over the linked virtual network are enabled. Defaults to `false`. */ virtualNetworkBackupRestoreEnabled?: pulumi.Input; /** * Whether traffic for the image pull should be routed over the virtual network. * * > **Note:** `virtualNetworkImagePullEnabled` must be set to `true` when running in an App Service Environment. */ virtualNetworkImagePullEnabled?: pulumi.Input; /** * The subnet id which will be used by this Web App Slot for [regional virtual network integration](https://docs.microsoft.com/en-us/azure/app-service/overview-vnet-integration#regional-virtual-network-integration). * * > **Note:** The AzureRM Terraform provider provides regional virtual network integration via the standalone resource appServiceVirtualNetworkSwiftConnection and in-line within this resource using the `virtualNetworkSubnetId` property. You cannot use both methods simultaneously. If the virtual network is set via the resource `appServiceVirtualNetworkSwiftConnection` then `ignoreChanges` should be used in the web app slot configuration. * * > **Note:** Assigning the `virtualNetworkSubnetId` property requires [RBAC permissions on the subnet](https://docs.microsoft.com/en-us/azure/app-service/overview-vnet-integration#permissions) */ virtualNetworkSubnetId?: pulumi.Input; /** * Should the default WebDeploy Basic Authentication publishing credentials enabled. Defaults to `true`. * * > **Note:** Setting this value to true will disable the ability to use `zipDeployFile` which currently relies on the default publishing profile. */ webdeployPublishBasicAuthenticationEnabled?: pulumi.Input; /** * The local path and filename of the Zip packaged application to deploy to this Windows Web App. */ zipDeployFile?: pulumi.Input; } /** * The set of arguments for constructing a WindowsWebAppSlot resource. */ export interface WindowsWebAppSlotArgs { /** * The ID of the Windows Web App this Deployment Slot will be part of. Changing this forces a new Windows Web App to be created. */ appServiceId: pulumi.Input; /** * A map of key-value pairs of App Settings. */ appSettings?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * An `authSettings` block as defined below. */ authSettings?: pulumi.Input; /** * An `authSettingsV2` block as defined below. */ authSettingsV2?: pulumi.Input; /** * A `backup` block as defined below. */ backup?: pulumi.Input; /** * Should Client Affinity be enabled? */ clientAffinityEnabled?: pulumi.Input; /** * Should Client Certificates be enabled? */ clientCertificateEnabled?: pulumi.Input; /** * Paths to exclude when using client certificates, separated by ; */ clientCertificateExclusionPaths?: pulumi.Input; /** * The Client Certificate mode. Possible values are `Required`, `Optional`, and `OptionalInteractiveUser`. This property has no effect when `clientCertificateEnabled` is `false`. Defaults to `Required`. */ clientCertificateMode?: pulumi.Input; /** * One or more `connectionString` blocks as defined below. */ connectionStrings?: pulumi.Input[]>; /** * Should the Windows Web App Slot be enabled? Defaults to `true`. */ enabled?: pulumi.Input; /** * Should the default FTP Basic Authentication publishing profile be enabled. Defaults to `true`. */ ftpPublishBasicAuthenticationEnabled?: pulumi.Input; /** * Should the Windows Web App Slot require HTTPS connections. Defaults to `false`. */ httpsOnly?: pulumi.Input; /** * An `identity` block as defined below. */ identity?: pulumi.Input; /** * The User Assigned Identity ID used for accessing KeyVault secrets. The identity must be assigned to the application in the `identity` block. [For more information see - Access vaults with a user-assigned identity](https://docs.microsoft.com/azure/app-service/app-service-key-vault-references#access-vaults-with-a-user-assigned-identity) */ keyVaultReferenceIdentityId?: pulumi.Input; /** * A `logs` block as defined below. */ logs?: pulumi.Input; /** * The name which should be used for this Windows Web App Slot. Changing this forces a new Windows Web App Slot to be created. * * > **Note:** Terraform will perform a name availability check as part of the creation progress, if this Web App is part of an App Service Environment terraform will require Read permission on the App Service Environment for this to complete reliably. */ name?: pulumi.Input; /** * Should public network access be enabled for the Web App. Defaults to `true`. */ publicNetworkAccessEnabled?: pulumi.Input; /** * The ID of the Service Plan in which to run this slot. If not specified the same Service Plan as the Windows Web App will be used. * * > **Note:** `servicePlanId` should only be specified if it differs from the Service Plan of the associated Windows Web App. */ servicePlanId?: pulumi.Input; /** * A `siteConfig` block as defined below. */ siteConfig: pulumi.Input; /** * One or more `storageAccount` blocks as defined below. * * > **Note:** Using this value requires `WEBSITE_RUN_FROM_PACKAGE=1` to be set on the App in `appSettings`. Refer to the [Azure docs](https://docs.microsoft.com/en-us/azure/app-service/deploy-run-package) for further details. */ storageAccounts?: pulumi.Input[]>; /** * A mapping of tags which should be assigned to the Windows Web App Slot. */ tags?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * Whether backup and restore operations over the linked virtual network are enabled. Defaults to `false`. */ virtualNetworkBackupRestoreEnabled?: pulumi.Input; /** * Whether traffic for the image pull should be routed over the virtual network. * * > **Note:** `virtualNetworkImagePullEnabled` must be set to `true` when running in an App Service Environment. */ virtualNetworkImagePullEnabled?: pulumi.Input; /** * The subnet id which will be used by this Web App Slot for [regional virtual network integration](https://docs.microsoft.com/en-us/azure/app-service/overview-vnet-integration#regional-virtual-network-integration). * * > **Note:** The AzureRM Terraform provider provides regional virtual network integration via the standalone resource appServiceVirtualNetworkSwiftConnection and in-line within this resource using the `virtualNetworkSubnetId` property. You cannot use both methods simultaneously. If the virtual network is set via the resource `appServiceVirtualNetworkSwiftConnection` then `ignoreChanges` should be used in the web app slot configuration. * * > **Note:** Assigning the `virtualNetworkSubnetId` property requires [RBAC permissions on the subnet](https://docs.microsoft.com/en-us/azure/app-service/overview-vnet-integration#permissions) */ virtualNetworkSubnetId?: pulumi.Input; /** * Should the default WebDeploy Basic Authentication publishing credentials enabled. Defaults to `true`. * * > **Note:** Setting this value to true will disable the ability to use `zipDeployFile` which currently relies on the default publishing profile. */ webdeployPublishBasicAuthenticationEnabled?: pulumi.Input; /** * The local path and filename of the Zip packaged application to deploy to this Windows Web App. */ zipDeployFile?: pulumi.Input; }