OpenStack v4.1.3 published on Wednesday, Aug 21, 2024 by Pulumi
openstack.networking.getQosPolicy
Explore with Pulumi AI
Use this data source to get the ID of an available OpenStack QoS policy.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as openstack from "@pulumi/openstack";
const qosPolicy1 = openstack.networking.getQosPolicy({
name: "qos_policy_1",
});
import pulumi
import pulumi_openstack as openstack
qos_policy1 = openstack.networking.get_qos_policy(name="qos_policy_1")
package main
import (
"github.com/pulumi/pulumi-openstack/sdk/v4/go/openstack/networking"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := networking.LookupQosPolicy(ctx, &networking.LookupQosPolicyArgs{
Name: pulumi.StringRef("qos_policy_1"),
}, nil)
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 qosPolicy1 = OpenStack.Networking.GetQosPolicy.Invoke(new()
{
Name = "qos_policy_1",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.openstack.networking.NetworkingFunctions;
import com.pulumi.openstack.networking.inputs.GetQosPolicyArgs;
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 qosPolicy1 = NetworkingFunctions.getQosPolicy(GetQosPolicyArgs.builder()
.name("qos_policy_1")
.build());
}
}
variables:
qosPolicy1:
fn::invoke:
Function: openstack:networking:getQosPolicy
Arguments:
name: qos_policy_1
Using getQosPolicy
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getQosPolicy(args: GetQosPolicyArgs, opts?: InvokeOptions): Promise<GetQosPolicyResult>
function getQosPolicyOutput(args: GetQosPolicyOutputArgs, opts?: InvokeOptions): Output<GetQosPolicyResult>
def get_qos_policy(description: Optional[str] = None,
is_default: Optional[bool] = None,
name: Optional[str] = None,
project_id: Optional[str] = None,
region: Optional[str] = None,
shared: Optional[bool] = None,
tags: Optional[Sequence[str]] = None,
opts: Optional[InvokeOptions] = None) -> GetQosPolicyResult
def get_qos_policy_output(description: Optional[pulumi.Input[str]] = None,
is_default: Optional[pulumi.Input[bool]] = None,
name: Optional[pulumi.Input[str]] = None,
project_id: Optional[pulumi.Input[str]] = None,
region: Optional[pulumi.Input[str]] = None,
shared: Optional[pulumi.Input[bool]] = None,
tags: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetQosPolicyResult]
func LookupQosPolicy(ctx *Context, args *LookupQosPolicyArgs, opts ...InvokeOption) (*LookupQosPolicyResult, error)
func LookupQosPolicyOutput(ctx *Context, args *LookupQosPolicyOutputArgs, opts ...InvokeOption) LookupQosPolicyResultOutput
> Note: This function is named LookupQosPolicy
in the Go SDK.
public static class GetQosPolicy
{
public static Task<GetQosPolicyResult> InvokeAsync(GetQosPolicyArgs args, InvokeOptions? opts = null)
public static Output<GetQosPolicyResult> Invoke(GetQosPolicyInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetQosPolicyResult> getQosPolicy(GetQosPolicyArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: openstack:networking/getQosPolicy:getQosPolicy
arguments:
# arguments dictionary
The following arguments are supported:
- Description string
- The human-readable description for the QoS policy.
- Is
Default bool - Whether the QoS policy is default policy or not.
- Name string
- The name of the QoS policy.
- Project
Id string - The owner of the QoS policy.
- Region string
- The region in which to obtain the V2 Networking client.
A Networking client is needed to retrieve a QoS policy ID. If omitted, the
region
argument of the provider is used. - bool
- Whether this QoS policy is shared across all projects.
- List<string>
- The list of QoS policy tags to filter.
- Description string
- The human-readable description for the QoS policy.
- Is
Default bool - Whether the QoS policy is default policy or not.
- Name string
- The name of the QoS policy.
- Project
Id string - The owner of the QoS policy.
- Region string
- The region in which to obtain the V2 Networking client.
A Networking client is needed to retrieve a QoS policy ID. If omitted, the
region
argument of the provider is used. - bool
- Whether this QoS policy is shared across all projects.
- []string
- The list of QoS policy tags to filter.
- description String
- The human-readable description for the QoS policy.
- is
Default Boolean - Whether the QoS policy is default policy or not.
- name String
- The name of the QoS policy.
- project
Id String - The owner of the QoS policy.
- region String
- The region in which to obtain the V2 Networking client.
A Networking client is needed to retrieve a QoS policy ID. If omitted, the
region
argument of the provider is used. - Boolean
- Whether this QoS policy is shared across all projects.
- List<String>
- The list of QoS policy tags to filter.
- description string
- The human-readable description for the QoS policy.
- is
Default boolean - Whether the QoS policy is default policy or not.
- name string
- The name of the QoS policy.
- project
Id string - The owner of the QoS policy.
- region string
- The region in which to obtain the V2 Networking client.
A Networking client is needed to retrieve a QoS policy ID. If omitted, the
region
argument of the provider is used. - boolean
- Whether this QoS policy is shared across all projects.
- string[]
- The list of QoS policy tags to filter.
- description str
- The human-readable description for the QoS policy.
- is_
default bool - Whether the QoS policy is default policy or not.
- name str
- The name of the QoS policy.
- project_
id str - The owner of the QoS policy.
- region str
- The region in which to obtain the V2 Networking client.
A Networking client is needed to retrieve a QoS policy ID. If omitted, the
region
argument of the provider is used. - bool
- Whether this QoS policy is shared across all projects.
- Sequence[str]
- The list of QoS policy tags to filter.
- description String
- The human-readable description for the QoS policy.
- is
Default Boolean - Whether the QoS policy is default policy or not.
- name String
- The name of the QoS policy.
- project
Id String - The owner of the QoS policy.
- region String
- The region in which to obtain the V2 Networking client.
A Networking client is needed to retrieve a QoS policy ID. If omitted, the
region
argument of the provider is used. - Boolean
- Whether this QoS policy is shared across all projects.
- List<String>
- The list of QoS policy tags to filter.
getQosPolicy Result
The following output properties are available:
- List<string>
- The set of string tags applied on the QoS policy.
- Created
At string - The time at which QoS policy was created.
- Description string
- See Argument Reference above.
- Id string
- The provider-assigned unique ID for this managed resource.
- Is
Default bool - See Argument Reference above.
- Name string
- See Argument Reference above.
- Project
Id string - Region string
- See Argument Reference above.
- Revision
Number int - The revision number of the QoS policy.
- bool
- See Argument Reference above.
- Updated
At string - The time at which QoS policy was created.
- List<string>
- []string
- The set of string tags applied on the QoS policy.
- Created
At string - The time at which QoS policy was created.
- Description string
- See Argument Reference above.
- Id string
- The provider-assigned unique ID for this managed resource.
- Is
Default bool - See Argument Reference above.
- Name string
- See Argument Reference above.
- Project
Id string - Region string
- See Argument Reference above.
- Revision
Number int - The revision number of the QoS policy.
- bool
- See Argument Reference above.
- Updated
At string - The time at which QoS policy was created.
- []string
- List<String>
- The set of string tags applied on the QoS policy.
- created
At String - The time at which QoS policy was created.
- description String
- See Argument Reference above.
- id String
- The provider-assigned unique ID for this managed resource.
- is
Default Boolean - See Argument Reference above.
- name String
- See Argument Reference above.
- project
Id String - region String
- See Argument Reference above.
- revision
Number Integer - The revision number of the QoS policy.
- Boolean
- See Argument Reference above.
- updated
At String - The time at which QoS policy was created.
- List<String>
- string[]
- The set of string tags applied on the QoS policy.
- created
At string - The time at which QoS policy was created.
- description string
- See Argument Reference above.
- id string
- The provider-assigned unique ID for this managed resource.
- is
Default boolean - See Argument Reference above.
- name string
- See Argument Reference above.
- project
Id string - region string
- See Argument Reference above.
- revision
Number number - The revision number of the QoS policy.
- boolean
- See Argument Reference above.
- updated
At string - The time at which QoS policy was created.
- string[]
- Sequence[str]
- The set of string tags applied on the QoS policy.
- created_
at str - The time at which QoS policy was created.
- description str
- See Argument Reference above.
- id str
- The provider-assigned unique ID for this managed resource.
- is_
default bool - See Argument Reference above.
- name str
- See Argument Reference above.
- project_
id str - region str
- See Argument Reference above.
- revision_
number int - The revision number of the QoS policy.
- bool
- See Argument Reference above.
- updated_
at str - The time at which QoS policy was created.
- Sequence[str]
- List<String>
- The set of string tags applied on the QoS policy.
- created
At String - The time at which QoS policy was created.
- description String
- See Argument Reference above.
- id String
- The provider-assigned unique ID for this managed resource.
- is
Default Boolean - See Argument Reference above.
- name String
- See Argument Reference above.
- project
Id String - region String
- See Argument Reference above.
- revision
Number Number - The revision number of the QoS policy.
- Boolean
- See Argument Reference above.
- updated
At String - The time at which QoS policy was created.
- List<String>
Package Details
- Repository
- OpenStack pulumi/pulumi-openstack
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
openstack
Terraform Provider.