FleetStackAssociation class

Manages an AppStream Fleet Stack association.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const example = new aws.appstream.Fleet("example", {
    computeCapacity: {
        desiredInstances: 1,
    },
    name: "NAME",
    imageName: "Amazon-AppStream2-Sample-Image-03-11-2023",
    instanceType: "stream.standard.small",
});
const exampleStack = new aws.appstream.Stack("example", {name: "STACK NAME"});
const exampleFleetStackAssociation = new aws.appstream.FleetStackAssociation("example", {
    fleetName: example.name,
    stackName: exampleStack.name,
});
import pulumi
import pulumi_aws as aws

example = aws.appstream.Fleet("example",
    compute_capacity={
        "desired_instances": 1,
    },
    name="NAME",
    image_name="Amazon-AppStream2-Sample-Image-03-11-2023",
    instance_type="stream.standard.small")
example_stack = aws.appstream.Stack("example", name="STACK NAME")
example_fleet_stack_association = aws.appstream.FleetStackAssociation("example",
    fleet_name=example.name,
    stack_name=example_stack.name)
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;

return await Deployment.RunAsync(() =>
{
    var example = new Aws.AppStream.Fleet("example", new()
    {
        ComputeCapacity = new Aws.AppStream.Inputs.FleetComputeCapacityArgs
        {
            DesiredInstances = 1,
        },
        Name = "NAME",
        ImageName = "Amazon-AppStream2-Sample-Image-03-11-2023",
        InstanceType = "stream.standard.small",
    });

    var exampleStack = new Aws.AppStream.Stack("example", new()
    {
        Name = "STACK NAME",
    });

    var exampleFleetStackAssociation = new Aws.AppStream.FleetStackAssociation("example", new()
    {
        FleetName = example.Name,
        StackName = exampleStack.Name,
    });

});
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v7/go/aws/appstream"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		example, err := appstream.NewFleet(ctx, "example", &appstream.FleetArgs{
			ComputeCapacity: &appstream.FleetComputeCapacityArgs{
				DesiredInstances: pulumi.Int(1),
			},
			Name:         pulumi.String("NAME"),
			ImageName:    pulumi.String("Amazon-AppStream2-Sample-Image-03-11-2023"),
			InstanceType: pulumi.String("stream.standard.small"),
		})
		if err != nil {
			return err
		}
		exampleStack, err := appstream.NewStack(ctx, "example", &appstream.StackArgs{
			Name: pulumi.String("STACK NAME"),
		})
		if err != nil {
			return err
		}
		_, err = appstream.NewFleetStackAssociation(ctx, "example", &appstream.FleetStackAssociationArgs{
			FleetName: example.Name,
			StackName: exampleStack.Name,
		})
		if err != nil {
			return err
		}
		return nil
	})
}
pulumi {
  required_providers {
    aws = {
      source = "pulumi/aws"
    }
  }
}

resource "aws_appstream_fleet" "example" {
  compute_capacity = {
    desired_instances = 1
  }
  name          = "NAME"
  image_name    = "Amazon-AppStream2-Sample-Image-03-11-2023"
  instance_type = "stream.standard.small"
}
resource "aws_appstream_stack" "example" {
  name = "STACK NAME"
}
resource "aws_appstream_fleetstackassociation" "example" {
  fleet_name = aws_appstream_fleet.example.name
  stack_name = aws_appstream_stack.example.name
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.appstream.Fleet;
import com.pulumi.aws.appstream.FleetArgs;
import com.pulumi.aws.appstream.inputs.FleetComputeCapacityArgs;
import com.pulumi.aws.appstream.Stack;
import com.pulumi.aws.appstream.StackArgs;
import com.pulumi.aws.appstream.FleetStackAssociation;
import com.pulumi.aws.appstream.FleetStackAssociationArgs;
import java.util.ArrayList;
import java.util.Arrays;
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) {
        var example = new Fleet("example", FleetArgs.builder()
            .computeCapacity(FleetComputeCapacityArgs.builder()
                .desiredInstances(1)
                .build())
            .name("NAME")
            .imageName("Amazon-AppStream2-Sample-Image-03-11-2023")
            .instanceType("stream.standard.small")
            .build());

        var exampleStack = new Stack("exampleStack", StackArgs.builder()
            .name("STACK NAME")
            .build());

        var exampleFleetStackAssociation = new FleetStackAssociation("exampleFleetStackAssociation", FleetStackAssociationArgs.builder()
            .fleetName(example.name())
            .stackName(exampleStack.name())
            .build());

    }
}
resources:
  example:
    type: aws:appstream:Fleet
    properties:
      computeCapacity:
        desiredInstances: 1
      name: NAME
      imageName: Amazon-AppStream2-Sample-Image-03-11-2023
      instanceType: stream.standard.small
  exampleStack:
    type: aws:appstream:Stack
    name: example
    properties:
      name: STACK NAME
  exampleFleetStackAssociation:
    type: aws:appstream:FleetStackAssociation
    name: example
    properties:
      fleetName: ${example.name}
      stackName: ${exampleStack.name}

Import

Using pulumi import, import AppStream Stack Fleet Association using the fleetName and stackName separated by a slash (/). For example:

$ pulumi import aws:appstream/fleetStackAssociation:FleetStackAssociation example fleetName/stackName

Constructors

FleetStackAssociation(String name, {FleetStackAssociationArgs? args, CustomResourceOptions? options})
Creates a new FleetStackAssociation. name The Pulumi resource name. args Arguments used to configure this FleetStackAssociation. The set of arguments for FleetStackAssociation. options Resource options controlling this resource's behavior.
FleetStackAssociation.reference(String urn)
Creates a typed reference to an existing FleetStackAssociation resource.

Properties

childResources → Set<Resource>
finalinherited
completionSources ↔ Map<String, IOutputCompletionSource>
latefinalinherited
fleetName ↔ Output<String>
Name of the fleet.
latefinal
hashCode → int
The hash code for this object.
no setterinherited
id ↔ Output<String>
getter/setter pairinherited
isCustom → bool
Returns whether this resource is provider-managed.
no setterinherited
isProtected → bool
Returns whether this resource is protected from deletion.
no setterinherited
isRemote → bool
Whether this resource is registered as remote.
no setterinherited
isResourceReference → bool
Whether this instance represents a resource value returned over RPC.
finalinherited
region ↔ Output<String>
Region where this resource will be managed. Defaults to the Region set in the provider configuration.
latefinal
resourceTransforms → List<ResourceTransform>
Inherited/explicit async transforms.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
stackName ↔ Output<String>
Name of the stack.
latefinal
transformations → List<ResourceTransformation>
Inherited/explicit legacy transformations.
no setterinherited
urn ↔ Output<String>
latefinalinherited

Methods

failId(Object error) → void
Completes this resource ID with an error when registration fails.
inherited
failOutputs(Object error) → void
Completes all output properties with error.
inherited
failUrn(Object error) → void
Completes this resource URN with an error when registration fails.
inherited
getProvider(String moduleMember) → ProviderResource?
Returns provider for moduleMember's package, if configured.
inherited
getResourceName() → String
Returns this resource's logical name.
inherited
getResourceType() → String
Returns this resource's Pulumi type token.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
registerOutput<T>(String propertyName, {Object? decoder(Object?)?, bool isSecret = false}) → Output<T>
Registers a dynamic output property for this resource.
inherited
resolveId(String? value, {required bool isKnown}) → void
Resolves the provider-assigned ID for this resource.
inherited
resolveOutputs(Struct outputs) → void
Resolves all output properties from a monitor response payload.
inherited
resolveUrn(String value) → void
Resolves this resource's URN once assigned by the engine.
inherited
serializeProperties(Map<String, dynamic> properties) → Future<Struct>
Serializes resource properties for RPC transmission.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Methods

get(String name, Input<String> id, {FleetStackAssociationState? state, CustomResourceOptions? options}) → FleetStackAssociation
Gets an existing FleetStackAssociation resource's state with the given name and id.