1. Packages
  2. Openstack Provider
  3. API Docs
  4. loadbalancer
  5. FlavorprofileV2
OpenStack v5.0.4 published on Tuesday, Apr 29, 2025 by Pulumi

openstack.loadbalancer.FlavorprofileV2

Explore with Pulumi AI

openstack logo
OpenStack v5.0.4 published on Tuesday, Apr 29, 2025 by Pulumi

    Manages a V2 load balancer flavorprofile resource within OpenStack.

    Note: This usually requires admin privileges.

    Example Usage

    Using jsonencode

    import * as pulumi from "@pulumi/pulumi";
    import * as openstack from "@pulumi/openstack";
    
    const flavorprofile1 = new openstack.loadbalancer.FlavorprofileV2("flavorprofile_1", {
        name: "amphora-single-profile",
        providerName: "amphora",
        flavorData: JSON.stringify({
            loadbalancer_topology: "SINGLE",
        }),
    });
    
    import pulumi
    import json
    import pulumi_openstack as openstack
    
    flavorprofile1 = openstack.loadbalancer.FlavorprofileV2("flavorprofile_1",
        name="amphora-single-profile",
        provider_name="amphora",
        flavor_data=json.dumps({
            "loadbalancer_topology": "SINGLE",
        }))
    
    package main
    
    import (
    	"encoding/json"
    
    	"github.com/pulumi/pulumi-openstack/sdk/v5/go/openstack/loadbalancer"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		tmpJSON0, err := json.Marshal(map[string]interface{}{
    			"loadbalancer_topology": "SINGLE",
    		})
    		if err != nil {
    			return err
    		}
    		json0 := string(tmpJSON0)
    		_, err = loadbalancer.NewFlavorprofileV2(ctx, "flavorprofile_1", &loadbalancer.FlavorprofileV2Args{
    			Name:         pulumi.String("amphora-single-profile"),
    			ProviderName: pulumi.String("amphora"),
    			FlavorData:   pulumi.String(json0),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using System.Text.Json;
    using Pulumi;
    using OpenStack = Pulumi.OpenStack;
    
    return await Deployment.RunAsync(() => 
    {
        var flavorprofile1 = new OpenStack.LoadBalancer.FlavorprofileV2("flavorprofile_1", new()
        {
            Name = "amphora-single-profile",
            ProviderName = "amphora",
            FlavorData = JsonSerializer.Serialize(new Dictionary<string, object?>
            {
                ["loadbalancer_topology"] = "SINGLE",
            }),
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.openstack.loadbalancer.FlavorprofileV2;
    import com.pulumi.openstack.loadbalancer.FlavorprofileV2Args;
    import static com.pulumi.codegen.internal.Serialization.*;
    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) {
            var flavorprofile1 = new FlavorprofileV2("flavorprofile1", FlavorprofileV2Args.builder()
                .name("amphora-single-profile")
                .providerName("amphora")
                .flavorData(serializeJson(
                    jsonObject(
                        jsonProperty("loadbalancer_topology", "SINGLE")
                    )))
                .build());
    
        }
    }
    
    resources:
      flavorprofile1:
        type: openstack:loadbalancer:FlavorprofileV2
        name: flavorprofile_1
        properties:
          name: amphora-single-profile
          providerName: amphora
          flavorData:
            fn::toJSON:
              loadbalancer_topology: SINGLE
    

    Using plain string

    import * as pulumi from "@pulumi/pulumi";
    import * as openstack from "@pulumi/openstack";
    
    const flavorprofile1 = new openstack.loadbalancer.FlavorprofileV2("flavorprofile_1", {
        name: "amphora-single-profile",
        providerName: "amphora",
        flavorData: "{\"loadbalancer_topology\": \"SINGLE\"}",
    });
    
    import pulumi
    import pulumi_openstack as openstack
    
    flavorprofile1 = openstack.loadbalancer.FlavorprofileV2("flavorprofile_1",
        name="amphora-single-profile",
        provider_name="amphora",
        flavor_data="{\"loadbalancer_topology\": \"SINGLE\"}")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-openstack/sdk/v5/go/openstack/loadbalancer"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := loadbalancer.NewFlavorprofileV2(ctx, "flavorprofile_1", &loadbalancer.FlavorprofileV2Args{
    			Name:         pulumi.String("amphora-single-profile"),
    			ProviderName: pulumi.String("amphora"),
    			FlavorData:   pulumi.String("{\"loadbalancer_topology\": \"SINGLE\"}"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using OpenStack = Pulumi.OpenStack;
    
    return await Deployment.RunAsync(() => 
    {
        var flavorprofile1 = new OpenStack.LoadBalancer.FlavorprofileV2("flavorprofile_1", new()
        {
            Name = "amphora-single-profile",
            ProviderName = "amphora",
            FlavorData = "{\"loadbalancer_topology\": \"SINGLE\"}",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.openstack.loadbalancer.FlavorprofileV2;
    import com.pulumi.openstack.loadbalancer.FlavorprofileV2Args;
    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) {
            var flavorprofile1 = new FlavorprofileV2("flavorprofile1", FlavorprofileV2Args.builder()
                .name("amphora-single-profile")
                .providerName("amphora")
                .flavorData("{\"loadbalancer_topology\": \"SINGLE\"}")
                .build());
    
        }
    }
    
    resources:
      flavorprofile1:
        type: openstack:loadbalancer:FlavorprofileV2
        name: flavorprofile_1
        properties:
          name: amphora-single-profile
          providerName: amphora
          flavorData: '{"loadbalancer_topology": "SINGLE"}'
    

    Create FlavorprofileV2 Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new FlavorprofileV2(name: string, args: FlavorprofileV2Args, opts?: CustomResourceOptions);
    @overload
    def FlavorprofileV2(resource_name: str,
                        args: FlavorprofileV2Args,
                        opts: Optional[ResourceOptions] = None)
    
    @overload
    def FlavorprofileV2(resource_name: str,
                        opts: Optional[ResourceOptions] = None,
                        flavor_data: Optional[str] = None,
                        provider_name: Optional[str] = None,
                        name: Optional[str] = None,
                        region: Optional[str] = None)
    func NewFlavorprofileV2(ctx *Context, name string, args FlavorprofileV2Args, opts ...ResourceOption) (*FlavorprofileV2, error)
    public FlavorprofileV2(string name, FlavorprofileV2Args args, CustomResourceOptions? opts = null)
    public FlavorprofileV2(String name, FlavorprofileV2Args args)
    public FlavorprofileV2(String name, FlavorprofileV2Args args, CustomResourceOptions options)
    
    type: openstack:loadbalancer:FlavorprofileV2
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args FlavorprofileV2Args
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args FlavorprofileV2Args
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args FlavorprofileV2Args
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args FlavorprofileV2Args
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args FlavorprofileV2Args
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var flavorprofileV2Resource = new OpenStack.LoadBalancer.FlavorprofileV2("flavorprofileV2Resource", new()
    {
        FlavorData = "string",
        ProviderName = "string",
        Name = "string",
        Region = "string",
    });
    
    example, err := loadbalancer.NewFlavorprofileV2(ctx, "flavorprofileV2Resource", &loadbalancer.FlavorprofileV2Args{
    	FlavorData:   pulumi.String("string"),
    	ProviderName: pulumi.String("string"),
    	Name:         pulumi.String("string"),
    	Region:       pulumi.String("string"),
    })
    
    var flavorprofileV2Resource = new FlavorprofileV2("flavorprofileV2Resource", FlavorprofileV2Args.builder()
        .flavorData("string")
        .providerName("string")
        .name("string")
        .region("string")
        .build());
    
    flavorprofile_v2_resource = openstack.loadbalancer.FlavorprofileV2("flavorprofileV2Resource",
        flavor_data="string",
        provider_name="string",
        name="string",
        region="string")
    
    const flavorprofileV2Resource = new openstack.loadbalancer.FlavorprofileV2("flavorprofileV2Resource", {
        flavorData: "string",
        providerName: "string",
        name: "string",
        region: "string",
    });
    
    type: openstack:loadbalancer:FlavorprofileV2
    properties:
        flavorData: string
        name: string
        providerName: string
        region: string
    

    FlavorprofileV2 Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The FlavorprofileV2 resource accepts the following input properties:

    FlavorData string
    String that passes the flavor_data for the flavorprofile. The data that are allowed depend on the provider_name that is passed. jsonencode can be used for readability as shown in the example above. Changing this updates the existing flavorprofile.
    ProviderName string
    The provider_name that the flavor_profile will use. Changing this updates the existing flavorprofile.
    Name string
    Name of the flavorprofile. Changing this updates the existing flavorprofile.
    Region string
    FlavorData string
    String that passes the flavor_data for the flavorprofile. The data that are allowed depend on the provider_name that is passed. jsonencode can be used for readability as shown in the example above. Changing this updates the existing flavorprofile.
    ProviderName string
    The provider_name that the flavor_profile will use. Changing this updates the existing flavorprofile.
    Name string
    Name of the flavorprofile. Changing this updates the existing flavorprofile.
    Region string
    flavorData String
    String that passes the flavor_data for the flavorprofile. The data that are allowed depend on the provider_name that is passed. jsonencode can be used for readability as shown in the example above. Changing this updates the existing flavorprofile.
    providerName String
    The provider_name that the flavor_profile will use. Changing this updates the existing flavorprofile.
    name String
    Name of the flavorprofile. Changing this updates the existing flavorprofile.
    region String
    flavorData string
    String that passes the flavor_data for the flavorprofile. The data that are allowed depend on the provider_name that is passed. jsonencode can be used for readability as shown in the example above. Changing this updates the existing flavorprofile.
    providerName string
    The provider_name that the flavor_profile will use. Changing this updates the existing flavorprofile.
    name string
    Name of the flavorprofile. Changing this updates the existing flavorprofile.
    region string
    flavor_data str
    String that passes the flavor_data for the flavorprofile. The data that are allowed depend on the provider_name that is passed. jsonencode can be used for readability as shown in the example above. Changing this updates the existing flavorprofile.
    provider_name str
    The provider_name that the flavor_profile will use. Changing this updates the existing flavorprofile.
    name str
    Name of the flavorprofile. Changing this updates the existing flavorprofile.
    region str
    flavorData String
    String that passes the flavor_data for the flavorprofile. The data that are allowed depend on the provider_name that is passed. jsonencode can be used for readability as shown in the example above. Changing this updates the existing flavorprofile.
    providerName String
    The provider_name that the flavor_profile will use. Changing this updates the existing flavorprofile.
    name String
    Name of the flavorprofile. Changing this updates the existing flavorprofile.
    region String

    Outputs

    All input properties are implicitly available as output properties. Additionally, the FlavorprofileV2 resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing FlavorprofileV2 Resource

    Get an existing FlavorprofileV2 resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: FlavorprofileV2State, opts?: CustomResourceOptions): FlavorprofileV2
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            flavor_data: Optional[str] = None,
            name: Optional[str] = None,
            provider_name: Optional[str] = None,
            region: Optional[str] = None) -> FlavorprofileV2
    func GetFlavorprofileV2(ctx *Context, name string, id IDInput, state *FlavorprofileV2State, opts ...ResourceOption) (*FlavorprofileV2, error)
    public static FlavorprofileV2 Get(string name, Input<string> id, FlavorprofileV2State? state, CustomResourceOptions? opts = null)
    public static FlavorprofileV2 get(String name, Output<String> id, FlavorprofileV2State state, CustomResourceOptions options)
    resources:  _:    type: openstack:loadbalancer:FlavorprofileV2    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    FlavorData string
    String that passes the flavor_data for the flavorprofile. The data that are allowed depend on the provider_name that is passed. jsonencode can be used for readability as shown in the example above. Changing this updates the existing flavorprofile.
    Name string
    Name of the flavorprofile. Changing this updates the existing flavorprofile.
    ProviderName string
    The provider_name that the flavor_profile will use. Changing this updates the existing flavorprofile.
    Region string
    FlavorData string
    String that passes the flavor_data for the flavorprofile. The data that are allowed depend on the provider_name that is passed. jsonencode can be used for readability as shown in the example above. Changing this updates the existing flavorprofile.
    Name string
    Name of the flavorprofile. Changing this updates the existing flavorprofile.
    ProviderName string
    The provider_name that the flavor_profile will use. Changing this updates the existing flavorprofile.
    Region string
    flavorData String
    String that passes the flavor_data for the flavorprofile. The data that are allowed depend on the provider_name that is passed. jsonencode can be used for readability as shown in the example above. Changing this updates the existing flavorprofile.
    name String
    Name of the flavorprofile. Changing this updates the existing flavorprofile.
    providerName String
    The provider_name that the flavor_profile will use. Changing this updates the existing flavorprofile.
    region String
    flavorData string
    String that passes the flavor_data for the flavorprofile. The data that are allowed depend on the provider_name that is passed. jsonencode can be used for readability as shown in the example above. Changing this updates the existing flavorprofile.
    name string
    Name of the flavorprofile. Changing this updates the existing flavorprofile.
    providerName string
    The provider_name that the flavor_profile will use. Changing this updates the existing flavorprofile.
    region string
    flavor_data str
    String that passes the flavor_data for the flavorprofile. The data that are allowed depend on the provider_name that is passed. jsonencode can be used for readability as shown in the example above. Changing this updates the existing flavorprofile.
    name str
    Name of the flavorprofile. Changing this updates the existing flavorprofile.
    provider_name str
    The provider_name that the flavor_profile will use. Changing this updates the existing flavorprofile.
    region str
    flavorData String
    String that passes the flavor_data for the flavorprofile. The data that are allowed depend on the provider_name that is passed. jsonencode can be used for readability as shown in the example above. Changing this updates the existing flavorprofile.
    name String
    Name of the flavorprofile. Changing this updates the existing flavorprofile.
    providerName String
    The provider_name that the flavor_profile will use. Changing this updates the existing flavorprofile.
    region String

    Import

    flavorprofiles can be imported using their id. Example:

    $ pulumi import openstack:loadbalancer/flavorprofileV2:FlavorprofileV2 flavorprofile_1 2a0f2240-c5e6-41de-896d-e80d97428d6b
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    OpenStack pulumi/pulumi-openstack
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the openstack Terraform Provider.
    openstack logo
    OpenStack v5.0.4 published on Tuesday, Apr 29, 2025 by Pulumi