getStacks

This data source provides the Ros Stacks of the current Alibaba Cloud user.

NOTE: Available in v1.106.0+.

Example Usage

Basic Usage

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.ros.RosFunctions;
import com.pulumi.alicloud.ros.inputs.GetStacksArgs;
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) {
final var example = RosFunctions.getStacks(GetStacksArgs.builder()
.ids("example_value")
.nameRegex("the_resource_name")
.build());
ctx.export("firstRosStackId", example.applyValue(getStacksResult -> getStacksResult.stacks()[0].id()));
}
}

Return

A collection of values returned by getStacks.

Parameters

argument

A collection of arguments for invoking getStacks.


suspend fun getStacks(enableDetails: Boolean? = null, ids: List<String>? = null, nameRegex: String? = null, outputFile: String? = null, parentStackId: String? = null, showNestedStack: Boolean? = null, stackName: String? = null, status: String? = null, tags: Map<String, Any>? = null): GetStacksResult

Return

A collection of values returned by getStacks.

See also

Parameters

enableDetails

Default to false. Set it to true can output more details about resource attributes.

ids

A list of Stack IDs.

nameRegex

A regex string to filter results by Stack name.

outputFile

File name where to save data source results (after running pulumi preview).

parentStackId

Parent Stack Id.

showNestedStack

The show nested stack.

stackName

Stack Name.

status

The status of Stack. Valid Values: CREATE_COMPLETE, CREATE_FAILED, CREATE_IN_PROGRESS, DELETE_COMPLETE, DELETE_FAILED, DELETE_IN_PROGRESS, ROLLBACK_COMPLETE, ROLLBACK_FAILED, ROLLBACK_IN_PROGRESS.

tags

Query the instance bound to the tag. The format of the incoming value is json string, including TagKey and TagValue. TagKey cannot be null, and TagValue can be empty. Format example {"key1":"value1"}.


suspend fun getStacks(argument: suspend GetStacksPlainArgsBuilder.() -> Unit): GetStacksResult

Return

A collection of values returned by getStacks.

See also

Parameters

argument

Builder for com.pulumi.alicloud.ros.kotlin.inputs.GetStacksPlainArgs.