Skip to content

Commit

Permalink
Resource Group - Delete Policy (#84)
Browse files Browse the repository at this point in the history
  • Loading branch information
fraliv13 authored Dec 12, 2023
1 parent 8fe3206 commit 73f1fe2
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,12 @@ func deployAzureRG(target provisioning.ProvisioningTarget, domain string) func(c
return fmt.Sprintf("%s-%s", platform.GetName(), domain)
},
)

pulumiRetainOnDelete := provisioning.GetDeletePolicy(target) == platformv1.DeletePolicyRetainStatefulResources

resourceGroup, err := azureResources.NewResourceGroup(ctx, resourceGroupName, &azureResources.ResourceGroupArgs{
ResourceGroupName: pulumi.String(resourceGroupName),
}, pulumi.RetainOnDelete(true))
}, pulumi.RetainOnDelete(pulumiRetainOnDelete))
if err != nil {
return pulumi.StringOutput{}, err
}
Expand Down

0 comments on commit 73f1fe2

Please sign in to comment.