Class ActiveSlot
Promotes an App Service Slot to Production within an App Service.
Note: When using Slots - the
app_settings,connection_stringandsite_configblocks on theazure.appservice.AppServiceresource will be overwritten when promoting a Slot using theazure.appservice.ActiveSlotresource.
Example Usage
using Pulumi;
using Azure = Pulumi.Azure;
using Random = Pulumi.Random;
class MyStack : Stack
{
public MyStack()
{
var server = new Random.RandomId("server", new Random.RandomIdArgs
{
});
// ...
var exampleResourceGroup = new Azure.Core.ResourceGroup("exampleResourceGroup", new Azure.Core.ResourceGroupArgs
{
});
// ...
var examplePlan = new Azure.AppService.Plan("examplePlan", new Azure.AppService.PlanArgs
{
});
// ...
var exampleAppService = new Azure.AppService.AppService("exampleAppService", new Azure.AppService.AppServiceArgs
{
});
// ...
var exampleSlot = new Azure.AppService.Slot("exampleSlot", new Azure.AppService.SlotArgs
{
});
// ...
var exampleActiveSlot = new Azure.AppService.ActiveSlot("exampleActiveSlot", new Azure.AppService.ActiveSlotArgs
{
ResourceGroupName = exampleResourceGroup.Name,
AppServiceName = exampleAppService.Name,
AppServiceSlotName = exampleSlot.Name,
});
}
}
Inherited Members
Namespace: Pulumi.Azure.AppService
Assembly: Pulumi.Azure.dll
Syntax
public class ActiveSlot : CustomResource
Constructors
View SourceActiveSlot(String, ActiveSlotArgs, CustomResourceOptions)
Create a ActiveSlot resource with the given unique name, arguments, and options.
Declaration
public ActiveSlot(string name, ActiveSlotArgs args, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| ActiveSlotArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceAppServiceName
The name of the App Service within which the Slot exists. Changing this forces a new resource to be created.
Declaration
public Output<string> AppServiceName { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
AppServiceSlotName
The name of the App Service Slot which should be promoted to the Production Slot within the App Service.
Declaration
public Output<string> AppServiceSlotName { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
ResourceGroupName
The name of the resource group in which the App Service exists. Changing this forces a new resource to be created.
Declaration
public Output<string> ResourceGroupName { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Methods
View SourceGet(String, Input<String>, ActiveSlotState, CustomResourceOptions)
Get an existing ActiveSlot resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static ActiveSlot Get(string name, Input<string> id, ActiveSlotState state = null, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resulting resource. |
| Input<System.String> | id | The unique provider ID of the resource to lookup. |
| ActiveSlotState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| ActiveSlot |