Show / Hide Table of Contents

Class WorkspaceStackState

Module class for manipulating stack state for a given WorkspaceStack.

Inheritance
object
WorkspaceStackState
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: Pulumi.Automation
Assembly: Pulumi.Automation.dll
Syntax
public sealed class WorkspaceStackState

Methods

View Source

DeleteAsync(string, bool, CancellationToken)

This command deletes a resource from a stack’s state, as long as it is safe to do so. The resource is specified by its Pulumi URN.

Resources can’t be deleted if there exist other resources that depend on it or are parented to it. Protected resources will not be deleted unless it is specifically requested using the force flag.
Declaration
public Task DeleteAsync(string urn, bool force = false, CancellationToken cancellationToken = default)
Parameters
Type Name Description
string urn

The Pulumi URN of the resource to be deleted.

bool force

A boolean indicating whether the deletion should be forced.

CancellationToken cancellationToken

A cancellation token.

Returns
Type Description
Task
View Source

UnprotectAllAsync(CancellationToken)

Unprotect all resources in a stack's state. This command clears the ‘protect’ bit on all resources in the stack, allowing those resources to be deleted.

Declaration
public Task UnprotectAllAsync(CancellationToken cancellationToken = default)
Parameters
Type Name Description
CancellationToken cancellationToken

A cancellation token.

Returns
Type Description
Task
View Source

UnprotectAsync(string, CancellationToken)

Unprotect a resource in a stack's state. This command clears the ‘protect’ bit on the provided resource urn, allowing the resource to be deleted.

Declaration
public Task UnprotectAsync(string urn, CancellationToken cancellationToken = default)
Parameters
Type Name Description
string urn

The Pulumi URN to be unprotected.

CancellationToken cancellationToken

A cancellation token.

Returns
Type Description
Task
  • View Source
Back to top Copyright 2016-2023, Pulumi Corporation.