outscale 1.0.1 published on Thursday, Mar 13, 2025 by outscale
outscale.getPolicy
Explore with Pulumi AI
Provides information about a policy.
For more information on this resource, see the User Guide.
For more information on this resource actions, see the API documentation.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as outscale from "@pulumi/outscale";
const userPolicy01 = outscale.getPolicy({
    policyOrn: "orn:ows:idauth::012345678910:policy/example/example-user-policy",
});
import pulumi
import pulumi_outscale as outscale
user_policy01 = outscale.get_policy(policy_orn="orn:ows:idauth::012345678910:policy/example/example-user-policy")
package main
import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/outscale/outscale"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := outscale.LookupPolicy(ctx, &outscale.LookupPolicyArgs{
			PolicyOrn: "orn:ows:idauth::012345678910:policy/example/example-user-policy",
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Outscale = Pulumi.Outscale;
return await Deployment.RunAsync(() => 
{
    var userPolicy01 = Outscale.GetPolicy.Invoke(new()
    {
        PolicyOrn = "orn:ows:idauth::012345678910:policy/example/example-user-policy",
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.outscale.OutscaleFunctions;
import com.pulumi.outscale.inputs.GetPolicyArgs;
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 userPolicy01 = OutscaleFunctions.getPolicy(GetPolicyArgs.builder()
            .policyOrn("orn:ows:idauth::012345678910:policy/example/example-user-policy")
            .build());
    }
}
variables:
  userPolicy01:
    fn::invoke:
      function: outscale:getPolicy
      arguments:
        policyOrn: orn:ows:idauth::012345678910:policy/example/example-user-policy
Using getPolicy
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 getPolicy(args: GetPolicyArgs, opts?: InvokeOptions): Promise<GetPolicyResult>
function getPolicyOutput(args: GetPolicyOutputArgs, opts?: InvokeOptions): Output<GetPolicyResult>def get_policy(id: Optional[str] = None,
               policy_orn: Optional[str] = None,
               opts: Optional[InvokeOptions] = None) -> GetPolicyResult
def get_policy_output(id: Optional[pulumi.Input[str]] = None,
               policy_orn: Optional[pulumi.Input[str]] = None,
               opts: Optional[InvokeOptions] = None) -> Output[GetPolicyResult]func LookupPolicy(ctx *Context, args *LookupPolicyArgs, opts ...InvokeOption) (*LookupPolicyResult, error)
func LookupPolicyOutput(ctx *Context, args *LookupPolicyOutputArgs, opts ...InvokeOption) LookupPolicyResultOutput> Note: This function is named LookupPolicy in the Go SDK.
public static class GetPolicy 
{
    public static Task<GetPolicyResult> InvokeAsync(GetPolicyArgs args, InvokeOptions? opts = null)
    public static Output<GetPolicyResult> Invoke(GetPolicyInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetPolicyResult> getPolicy(GetPolicyArgs args, InvokeOptions options)
public static Output<GetPolicyResult> getPolicy(GetPolicyArgs args, InvokeOptions options)
fn::invoke:
  function: outscale:index/getPolicy:getPolicy
  arguments:
    # arguments dictionaryThe following arguments are supported:
- PolicyOrn string
- The OUTSCALE Resource Name (ORN) of the policy. For more information, see Resource Identifiers.
- Id string
- PolicyOrn string
- The OUTSCALE Resource Name (ORN) of the policy. For more information, see Resource Identifiers.
- Id string
- policyOrn String
- The OUTSCALE Resource Name (ORN) of the policy. For more information, see Resource Identifiers.
- id String
- policyOrn string
- The OUTSCALE Resource Name (ORN) of the policy. For more information, see Resource Identifiers.
- id string
- policy_orn str
- The OUTSCALE Resource Name (ORN) of the policy. For more information, see Resource Identifiers.
- id str
- policyOrn String
- The OUTSCALE Resource Name (ORN) of the policy. For more information, see Resource Identifiers.
- id String
getPolicy Result
The following output properties are available:
- CreationDate string
- The date and time (UTC) at which the policy was created.
- Description string
- A friendly name for the policy (between 0 and 1000 characters).
- Document string
- Id string
- IsLinkable bool
- Indicates whether the policy can be linked to a group or an EIM user.
- LastModification stringDate 
- The date and time (UTC) at which the policy was last modified.
- Orn string
- The OUTSCALE Resource Name (ORN) of the policy. For more information, see Resource Identifiers.
- Path string
- The path to the policy.
- PolicyDefault stringVersion Id 
- The ID of the policy default version.
- PolicyId string
- The ID of the policy.
- PolicyName string
- The name of the policy.
- PolicyOrn string
- ResourcesCount double
- The number of resources attached to the policy.
- CreationDate string
- The date and time (UTC) at which the policy was created.
- Description string
- A friendly name for the policy (between 0 and 1000 characters).
- Document string
- Id string
- IsLinkable bool
- Indicates whether the policy can be linked to a group or an EIM user.
- LastModification stringDate 
- The date and time (UTC) at which the policy was last modified.
- Orn string
- The OUTSCALE Resource Name (ORN) of the policy. For more information, see Resource Identifiers.
- Path string
- The path to the policy.
- PolicyDefault stringVersion Id 
- The ID of the policy default version.
- PolicyId string
- The ID of the policy.
- PolicyName string
- The name of the policy.
- PolicyOrn string
- ResourcesCount float64
- The number of resources attached to the policy.
- creationDate String
- The date and time (UTC) at which the policy was created.
- description String
- A friendly name for the policy (between 0 and 1000 characters).
- document String
- id String
- isLinkable Boolean
- Indicates whether the policy can be linked to a group or an EIM user.
- lastModification StringDate 
- The date and time (UTC) at which the policy was last modified.
- orn String
- The OUTSCALE Resource Name (ORN) of the policy. For more information, see Resource Identifiers.
- path String
- The path to the policy.
- policyDefault StringVersion Id 
- The ID of the policy default version.
- policyId String
- The ID of the policy.
- policyName String
- The name of the policy.
- policyOrn String
- resourcesCount Double
- The number of resources attached to the policy.
- creationDate string
- The date and time (UTC) at which the policy was created.
- description string
- A friendly name for the policy (between 0 and 1000 characters).
- document string
- id string
- isLinkable boolean
- Indicates whether the policy can be linked to a group or an EIM user.
- lastModification stringDate 
- The date and time (UTC) at which the policy was last modified.
- orn string
- The OUTSCALE Resource Name (ORN) of the policy. For more information, see Resource Identifiers.
- path string
- The path to the policy.
- policyDefault stringVersion Id 
- The ID of the policy default version.
- policyId string
- The ID of the policy.
- policyName string
- The name of the policy.
- policyOrn string
- resourcesCount number
- The number of resources attached to the policy.
- creation_date str
- The date and time (UTC) at which the policy was created.
- description str
- A friendly name for the policy (between 0 and 1000 characters).
- document str
- id str
- is_linkable bool
- Indicates whether the policy can be linked to a group or an EIM user.
- last_modification_ strdate 
- The date and time (UTC) at which the policy was last modified.
- orn str
- The OUTSCALE Resource Name (ORN) of the policy. For more information, see Resource Identifiers.
- path str
- The path to the policy.
- policy_default_ strversion_ id 
- The ID of the policy default version.
- policy_id str
- The ID of the policy.
- policy_name str
- The name of the policy.
- policy_orn str
- resources_count float
- The number of resources attached to the policy.
- creationDate String
- The date and time (UTC) at which the policy was created.
- description String
- A friendly name for the policy (between 0 and 1000 characters).
- document String
- id String
- isLinkable Boolean
- Indicates whether the policy can be linked to a group or an EIM user.
- lastModification StringDate 
- The date and time (UTC) at which the policy was last modified.
- orn String
- The OUTSCALE Resource Name (ORN) of the policy. For more information, see Resource Identifiers.
- path String
- The path to the policy.
- policyDefault StringVersion Id 
- The ID of the policy default version.
- policyId String
- The ID of the policy.
- policyName String
- The name of the policy.
- policyOrn String
- resourcesCount Number
- The number of resources attached to the policy.
Package Details
- Repository
- outscale outscale/terraform-provider-outscale
- License
- Notes
- This Pulumi package is based on the outscaleTerraform Provider.